subject

Write a function, computePrice(), that takes as two parameters: the age group and the ticket type, and returns the price for admission to the American Museum of Natural History. If the ticket type is "admission" and the age group is "adult", the price is $23. If the ticket type is "admission" and the age group is "child", the price is $13. If the ticket type is "admission" and the age group is "senior", the price is $18. If the ticket type is "+exhibitions" and the age group is "adult", the price is $33. If the ticket type is "+exhibitions" and the age group is "child", the price is $20. If the ticket type is "+exhibitions" and the age group is "senior", the price is $27. If the ticket type or age group are not one of the above, it returns -1.

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 01:30
Someone wishes to run the software on another computer system that runs an operating system that does not support the software what can he do
Answers: 3
question
Computers and Technology, 22.06.2019 18:00
What is the first view you place in your drawing?
Answers: 1
question
Computers and Technology, 22.06.2019 18:30
Kto rozmawia z clamentain przez krótkofalówke w the walking dead która śledzi lee w 4 epizodzie
Answers: 1
question
Computers and Technology, 22.06.2019 18:30
If an improvement creates no significant change in a product’s performance, then it is a(n) ? a0 design improvement. (there are no answer choices)
Answers: 1
You know the right answer?
Write a function, computePrice(), that takes as two parameters: the age group and the ticket type, a...
Questions
question
English, 26.11.2020 06:40
question
Advanced Placement (AP), 26.11.2020 06:40
question
Arts, 26.11.2020 06:40
question
Mathematics, 26.11.2020 06:40