I think you need to think about this problem again before trying to solve it. You ask for one persons age, are you assuming that everyone in the group is the same age?
Your interface seems flawed to me. Rather than enter each individuals age (which you don't do at the moment, so how can you possibly be charging the correct price?) why not simply prompt for how many kids, adults and over 60s there are, you'd then know the total number of people and the entry price, at which point if there are >= 6 people apply the discount.
Now on to your code. You should read about chomping your input. If you're new to perl see:
If you have any other problems let us know. Please don't ignore formatting advice given when composing posts. See How do I post a question effectively? and Writeup Formatting Tips.
In reply to Re: Perl Programming help required
by marto
in thread Perl Programming help required
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |