Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Across campus, Petey is planning his revenge. He will open his own ice cream shop by the reflection pond. It will be great, he thinks.

Across campus, Petey is planning his revenge. He will open his own ice cream shop by the reflection pond. It will be great, he thinks.
However, his pricing is very tricky. He will ask you a series of questions, and depending on your answers you will be charged different amounts. Here are his questions:
How many years have you been at UCF (the first year is 1)?
What is your favorite ice cream?
What is your name?
Petey knows that it is easier to hook new students and older students will be gone soon. So he will take the years you have attended UCF and multiply it by $5.
He really wants to sell mint ice cream, and if you type in "mint" he will take off 50% rounded down. He doesn't like change You may assume that the user will always type in mint all lowercase.
He does nothing with this information unless your name is "Knightro". Then the price of your food is $1,000.
Can you write this program for Petey?
Sample
image text in transcribed

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Systems Introduction To Databases And Data Warehouses

Authors: Nenad Jukic, Susan Vrbsky, Svetlozar Nestorov

1st Edition

1943153191, 978-1943153190

More Books

Students also viewed these Databases questions

Question

4. Explain how to price managerial and professional jobs.pg 87

Answered: 1 week ago