0

Can anyone solve it

You are making a ticketing system. The price of a single ticket is $100. For children under 3 years of age, the ticket is free. Your program needs to take the ages of 5 passengers as input and output the total price for their tickets. Sample Input 18 24 2 5 42 Sample Output 400

27th Dec 2022, 2:31 PM
Siddhartha Ojha
Siddhartha Ojha - avatar
3 Answers
+ 6
Many people have solved it. In order for us to help you, we need to see where you're stuck. Review the lessons before the task and try again. If it doesn't work, copy your code, go to the code playground, paste it there and attach that here.
27th Dec 2022, 2:32 PM
Ausgrindtube
Ausgrindtube - avatar
+ 3
classic bait 😁. if you're smart enough to use this trick to get answer for free, you're smart enough to solve it yourself.
27th Dec 2022, 2:46 PM
Bob_Li
Bob_Li - avatar
+ 1
I have solved it too. Just think about it, try to use if statements, and review the lesson, as Ausgrindtube have suggested
27th Dec 2022, 2:41 PM
Lamron
Lamron - avatar