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
Katarina [22]
2 years ago
7

1. Write a high level algorithm for cooking a cheeseburger.

Computers and Technology
1 answer:
pishuonlain [190]2 years ago
7 0

Answer:

1.  A high level algorithm for cooking a cheeseburger could be:

  1. Heat fry pan
  2. Cook one side of the hamburger
  3. Wait
  4. Turn hamburger upside down
  5. Put cheese over hamburger
  6. Wait
  7. Cut hamburger bread in half
  8. Put cooked hamburger inside bread
  9. End (eat)

2. A detailed algorithm for cooking a cheeseburger could be:

  1. Place fry pan over the stove heater
  2. Turn on heater (max temp)
  3. IF fry pan not hot: wait, else continue
  4. Place raw hamburger on fry pan
  5. IF hamburger not half cooked: Wait X time then go to line 5, else continue
  6. Turn hamburger upside down
  7. Put N slices of cheese over hamburger
  8. IF hamburger not fully cooked: Wait X time then go to line 8, else continue
  9. Turn off heater
  10. Cut hamburger bread in half horizontally
  11. Put cooked hamburger on one of the bread halves.
  12. Put second bread half on top of hamburger
  13. End (eat)

Explanation:

An algorithm is simply a list of steps to perform a defined action.

On 1, we described the most relevant steps to cook a simple cheeseburger.

Then on point 2, the same steps were taken and expanded with more detailed steps and conditions required to continue executing the following steps.

In computational terms, we used pseudo-code for the algorithm, since this is a list of actions not specific to any programming language.

Also we can say this is a structured programming example due to the sequential nature of the cooking process.

You might be interested in
Which of the following is true regarding the use of instance variable j in class B1?
melisa1 [442]

Answer: A) It is directly accessible only in B1

Explanation: In the given chunk of code, Class B1 is a base class. Class B2 is derived class of class B1. Class B3 is derived class of B2. As you can see class B1 has two members or instance variables i and j. Instance variable cannot be directly accessible by both B2 and B3. If you see this statement of the given code  private int j; the keyword private is used with the variable j. This keyword is called access specifier. Access specifiers specifies how the members of a class can be accessed. These members are attributes and methods of that class. Any member of a class that are declared private cannot be inherited by derived classes of that class.  Additionally these private members cannot be accessed from within any method inside derived class. So j is directly accessible only in B1. You can access a private instance variable from within the same class or can access  it through the methods of class.

6 0
3 years ago
int temp; temp = 180; if ( temp > 90 ) { System.out.println( "This porridge is too hot." ); // cool down temp = temp – ( temp
STALIN [3.7K]

Answer:

The combined output will be option D which is

This porridge is too hot.

This porridge is just right!

Explanation:

As the complete question is not the given the complete question is found online and is attached herewith.

Now from the given attached code

As the temperature value is 180 which is more than 90 so the first loop is true and the first print out is

This porridge is too hot.

Now the temperature is cooled down using the formula such that the temperature reduced 100 degrees in the intervals of 20 now the temperature becomes 80. As it is greater than 70, thus the second if loop is not executed.

As the temperature is 80 this the next print out will be as

This porridge is just right!

So the combined output will be option D which is

This porridge is too hot.

This porridge is just right!

3 0
3 years ago
2.4 Code Practice: Question 2
klasskru [66]

num = float(input("Enter a number: "))

num1 = int(num)

print(num - num1)

I hope this helps!

8 0
2 years ago
Write a program that will take an integer and add up each of the number’s digits, count the number of digits in the number, and
Inga [223]
For count digits, you could just convert it to a String and check the length
Sum digits, convert to string then seperate each character with charAt then convert it to numbers in the return statement.
Average digits you can convert it to a String and then convert them back after taking them apart.
5 0
2 years ago
Read 2 more answers
What are the four major software packages of microsoft​
Reika [66]

Answer:

» Microsoft word ( word processing )

» Microsoft powerpoint ( presentation )

» Microsoft access ( database mamagement )

» Microsoft excel ( spread sheets )

Explanation:

.

3 0
2 years ago
Other questions:
  • Cleo finds herself frequently searching for messages from particular senders or with specific subjects. What should she create
    5·1 answer
  • Do most facebook and twitter users access the platform from their personal computers?
    6·2 answers
  • After a robbery, what is the purpose of conducting a neighborhood canvass?
    9·1 answer
  • How to upload themes to chrome web store
    11·1 answer
  • What is a VIN and what role does it play during a criminal investigation? Explain how a VIN could help in a bomb and/or arson ca
    12·1 answer
  • HURRY!! Ill give brainily and 25 points. Describe how Scent is related to the culture and historical period when it was created.
    15·1 answer
  • Which button, when pressed, allows light from the subject to fall on the sensor?
    8·1 answer
  • In what year was the 1st zelda game released
    5·2 answers
  • When was the federal commission act put into effect?????
    13·1 answer
  • When designers follow accepted standards and protocols, which of the four basic characteristics of network architecture is achie
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!