1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
maxonik [38]
3 years ago
13

The cafeteria offers a discount card for sale that entitles you, during a certain period, to a free meal whenever you have bough

t a given number of meals at the regular price. The exact details of the offer change from time to time. Describe an algorithm that lets you determine whether a particular offer is a good buy. What other inputs do you need
Computers and Technology
1 answer:
melomori [17]3 years ago
8 0

Answer:

Explanation:

The algorithm can be described as follows

The first process is to ensure that the constraints for the time at which the offers begin is well defined.

TIME1 = 14:00

TIME2 = 16:00

TIME3 = 18:00

Then, decide the final number of meal following the free meal that has been offered.

NUMBER_OF_MEALS=4;

Then; decide the prices attached to the meal at regular times.

PRICE = 200;

At regular mode, decide the prices attached to the meal and as well as when the offer time commences.

PRICE_OFFER = 160;

Then ask the client(i.e the user) to put in the value required for the number of meals they desire to order.

Input values in n

Suppose (the value exceeds 8)

Then proceed to enquire from the client if they wish to go for the offer.

If not, use the regular price for the order.

Assume the client asks if the offer is a good one to bid for.

You are to show then the analysis of the calculation.

regular = 8 × PRICE

offer = 8 × PRICE_OFFER

profit = regular - offer

Finally, show the profit to the client which will let them know if it is good to bid for it or not.

You might be interested in
NoSQL is a programming language used to create mobile apps.<br> a) True<br> b) False
finlep [7]

Answer:

False

Explanation:

7 0
3 years ago
Read 2 more answers
The variable used in a loop to control the number of times it is executed is called a _______.
tia_tia [17]

Answer:

the variable used in a loop to control the number of timer is executed is called a interaction.

Explanation:

a particular way in which matter, fields, and atomic and subatomic particles affect one another

6 0
3 years ago
Assume there is an interactive math tutor. Many students take the math lessons online. At the end of each lesson, students have
Rus_ich [418]
Oh gosh oh I don’t wowiww
6 0
2 years ago
The function below takes two numeric parameters. The first parameter specifies the number of hours a person worked and the secon
Triss [41]

Answer:

def calculate_pay(total_worked_hours, rate_per_hour):

   if total_worked_hours > 40:

       return (40 * rate_per_hour) + ((total_worked_hours - 40) * 2 * rate_per_hour)

   else:

       return total_worked_hours * rate_per_hour

Explanation:

  • Create the calculate_pay function that takes 2 parameters.
  • Inside the function check whether the total_worked_hours is greater than 40 and then return the pay by calculating with the help of formula for work over 40 hours.
  • Otherwise return the pay by multiplying the total_worked_hours with rate_per_hour.
6 0
3 years ago
Full from of tmc computer
Butoxors [25]

Answer:

Traffic Message Channel,

7 0
3 years ago
Read 2 more answers
Other questions:
  • Write a program that asks the user to input four numbers (one at a time). After the four numbers have been supplied, it should t
    6·1 answer
  • By applying styles formats are being applied ?
    14·2 answers
  • "what should you do if the system continually reboots and you can't read the error message produced on a blue screen
    11·2 answers
  • If you want an app to reach the largest possible audience, which two platforms should you use?
    7·1 answer
  • Chevening is looking for individuals with strong professional relationship building skills, who will engage with the Chevening c
    15·1 answer
  • Which element in the PowerPoint application is not available in the Microsoft Word application?
    12·2 answers
  • What natural resource are available on the coast but not somewhereelse
    13·1 answer
  • Alexandria works for a non-profit company that asks for donations to help the homeless people in her community. Recently the dat
    12·1 answer
  • Design a class called NumDays. The class’s purpose is to store a value that represents a number of work hours and convert it to
    12·1 answer
  • What is 3x10? PLZZZZZ
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!