For this assignment, rather than the attached sandwich-making algorithm, we will use the Fibonacci sequence to illustrate algorithm description, pseudocode, and flowcharts.  Recall that the Fibonacci sequence starts with 2 integers, usually 1 1, and each successive number in the sequence is the sum of the 2 previous numbers.  So, starting with 1 1, the sequence begins 1 1 2 3 5 8 13 21....  Your algorithm will need to specify how the sequence starts, how successive numbers are generated, and how the sequence will stop.

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question

For this assignment, rather than the attached sandwich-making algorithm, we will use the Fibonacci sequence to illustrate algorithm description, pseudocode, and flowcharts.  Recall that the Fibonacci sequence starts with 2 integers, usually 1 1, and each successive number in the sequence is the sum of the 2 previous numbers.  So, starting with 1 1, the sequence begins 1 1 2 3 5 8 13 21....  Your algorithm will need to specify how the sequence starts, how successive numbers are generated, and how the sequence will stop.

Students will write code to send a user's sandwich order to the kitchen. The sandwich is made of 3
layers: bread must be on the outside (lettuce for gluten-free), and a single main ingredient chosen
by the user goes in the middle. The code should ask the user whether they want gluten-free and
for their choice of main ingredient. The code should print numbers to the serial monitor on
separate lines in the correct order of assembling the sandwich. A basic ingredient menu is shown.
99
44
1
3
4
2
Wheat bread
Lettuce
Turkey
Chicken Salad
Salami
Cheese
Example output
Please make this sandwich right away:
99
3
99
Assignment directions: Make a list of the steps the code must perform. Then, sort the steps into
the correct order. Once you have mastered the basic algorithm, add complexity to your sandwich
ordering system (if specified by your instructor).
Transcribed Image Text:Students will write code to send a user's sandwich order to the kitchen. The sandwich is made of 3 layers: bread must be on the outside (lettuce for gluten-free), and a single main ingredient chosen by the user goes in the middle. The code should ask the user whether they want gluten-free and for their choice of main ingredient. The code should print numbers to the serial monitor on separate lines in the correct order of assembling the sandwich. A basic ingredient menu is shown. 99 44 1 3 4 2 Wheat bread Lettuce Turkey Chicken Salad Salami Cheese Example output Please make this sandwich right away: 99 3 99 Assignment directions: Make a list of the steps the code must perform. Then, sort the steps into the correct order. Once you have mastered the basic algorithm, add complexity to your sandwich ordering system (if specified by your instructor).
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 4 steps with 1 images

Blurred answer
Knowledge Booster
Graphical User Interface
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education