Object-oriented Programming: OOP

๊ฐ์ฒด์ง€ํ–ฅ์˜ ์‚ฌ์‹ค๊ณผ ์˜คํ•ด

  1. ๊ฐ์ฒด์ง€ํ–ฅ ํŒจ๋Ÿฌ๋‹น๋ฏธ์˜ ํ•ต์‹ฌ์€ ์ž์œจ์ ์ธ ๊ฐ์ฒด๋“ค์˜ ํ˜‘๋ ฅํ•˜๋Š” ๊ฒƒ

  2. ๊ฐ์ฒด๋Š” ์ƒํƒœ์™€ ํ–‰๋™, ์‹๋ณ„์ž๋ฅผ ๊ฐ€์ง„ ์กด์žฌ

  3. ์ถ”์ƒํ™”๋Š” ๋™์ ์ธ ๊ฐ์ฒด๋“ค์„ ๋‹จ์ˆœํ™”์‹œ์ผœ ์ •์ ์ธ ํƒ€์ž…์œผ๋กœ ๊ฐˆ๋ฌด๋ฆฌํ•˜๋Š” ๊ฒƒ

  4. ๊ฐ์ฒด๋“ค์€ ํ˜‘๋ ฅ์— ์ฐธ์—ฌํ•˜๊ธฐ ์œ„ํ•ด ํŠน์ •ํ•œ ์—ญํ• ์„ ๋งก๊ณ  ์—ญํ• ์— ์ ํ•ฉํ•œ ์ฑ…์ž„์„ ์ˆ˜ํ–‰ํ•œ๋‹ค.

  5. ํ›Œ๋ฅญํ•œ ๋ฉ”์‹œ์ง€๋ฅผ ์„ ํƒํ•˜๋ฏ€๋กœ์จ ๊ฐ์ฒด์˜ ์ž์œจ์„ฑ๊ณผ ์„ค๊ณ„์˜ ์œ ์—ฐ์„ฑ์œผ๋กœ ๊ฐ์ฒด์ง€ํ–ฅ ์„ค๊ณ„์˜ ๊ธฐ๋ฐ˜์ด ๋œ๋‹ค๋Š” ๊ฒƒ

  6. ๊ฐ์ฒด์ง€ํ–ฅ ํŒจ๋Ÿฌ๋‹ค์ž„์€ ๊ฐ์ฒด๋“ค์˜ ๊ตฌ์กฐ์•ˆ์— ๊ธฐ๋Šฅ์„ ๋…น์ž„์œผ๋กœ์จ ๋ณ€ํ™”์— ์•ˆ์ •์ ์ธ ์†Œํ”„ํŠธ์›จ์–ด๋ฅผ ๊ฐœ๋ฐœํ•˜๋Š” ๊ฒƒ

  7. 1 ~ 6 ๊นŒ์ง€์˜ ์œ ๊ธฐ์ ์ธ ํ๋ฆ„์„ ์ฝ”๋“œ๋กœ ๋…น์—ฌ ๊ตฌํ˜„ํ•œ ๊ฒƒ

1. ํ˜‘๋ ฅํ•˜๋Š” ๊ฐ์ฒด๋“ค์˜ ๊ณต๋™์ฒด

์—ญํ• ๊ณผ ์ฑ…์ž„, ํ˜‘๋ ฅ์— ๋Œ€ํ•œ ์ด์•ผ๊ธฐ

์˜ค๋ธŒ์ ํŠธ

  • ์‹œ๋‚˜๋ฆฌ์˜ค ๋Œ€๋กœ 1์ฐจ ์ฝ”๋“œ ์ž‘์„ฑ

  • ๋ฌธ์ œ์ 

    • ์ฝ”๋“œ์˜ ๋กœ์ง์ด ํ•œ ๊ณณ์— ๋ชฐ๋ ค ์žˆ์–ด ๋ณ€๊ฒฝ์— ์ทจ์•ฝํ•จ

    • ๊ฐ์ฒด ์‚ฌ์ด์˜ ์˜์กด์„ฑ์ด ๋†’์Œ -> ๊ฒฐํ•ฉ๋„๊ฐ€ ๋†’์Œ

  • ํ•ด๊ฒฐ์ฑ…

    • ์ฑ…์ž„์˜ ์ด๋™

์˜ํ™” ์˜ˆ๋งค

  • NoneDiscountPolicy ์ถ”๊ฐ€

  • ์ธํ„ฐํŽ˜์ด์Šค ๋„์ž…

  • ๋ฆฌํŽ™ํ† ๋งํ•œ ๊ตฌ์กฐ๋„ ๊ฒฐ๊ตญ ํ• ์ธ ์ •์ฑ…์—์„œ ์ƒ์†์„ ์ด์šฉํ•˜๊ณ  ์žˆ๊ธฐ ๋•Œ๋ฌธ์— ์‹คํ–‰ ์ค‘์— ์˜ํ™”์˜ ํ• ์ธ ์ •์ฑ…์„ ๋ณ€๊ฒฝํ•˜๊ธฐ ์œ„ํ•ด์„œ ์ƒˆ๋กœ์šด ์ธ์Šคํ„ด์Šค๋ฅผ ์ƒ์„ฑํ•ด์•ผํ•œ๋‹ค.

  • ์ด ํ•ด๊ฒฐ ๋ฐฉ๋ฒ•์œผ๋กœ ํ•ฉ์„ฑ์„ ์ด์šฉํ•œ ๊ตฌ์กฐ๋กœ ๋ณ€๊ฒฝ ํ•ด์•ผ ํ•œ๋‹ค.

  • DiscountPolicy๋กœ ๋ถ„๋ฆฌํ•œ ๋’ค Movie์— ํ•ฉ์„ฑํ•˜์—ฌ ์œ ์—ฐํ•œ ์„ค๊ณ„๋ฅผ ํ•ด์•ผํ•œ๋‹ค.

Last updated

Was this helpful?