Check Discount Based On Age
- Create object with name and age value.
- Create a function check discount based on age.
- Discount based on age
- If age is between 40 to 50 then user get 40%
discounts
- If age is between 30 to 40then user get 30%
discounts
- If age is between 20 to 30 then user get 20%
discounts
- If age is between 0 to 20 then user get 10%
discounts
- If age is more then 50 +then user not able to get
any discount
- Show message on console if eligible discount like
Raju, you are eligible
for a 10% discount!
- If not eligible for discount then show Raju,
sorry, no discount available.
- Click button should create function.