You'll be creating a program that will find a donut shop at the user's provided zip-code and determine the number of drinks that the user can buy with their budget. Name your program DonutShop. java. First, your program should ask the user for their desired zip code. Using a switch statement block, you should determine what donut shop is at that zip code: ● ● 33511 is Dunkin Donuts 30328 is Tim Hortons 30356 is Krispy Kreme 30211 is Sublime If the zip code doesn't match any number, then it should print out "Sorry, no shops found." and the program will end. If there's a donut shop, you should print "There is a donut shop called [name] here!" then prompt the user for their budget (integer input). Next, using an if/else conditional block and the below cutoffs, determine the number of donuts the user will be able to purchase. ● A budget between $1 to $5 (inclusive) can purchase 2 donuts A budget between $6 to $11 (inclusive) can purchase 4 donuts A budget between $12 to $20 (inclusive) can purchase 8 donuts A budget greater than $20 can purchase 16 donuts All other budgets cannot purchase anything You should ask the user to enter the number of dollars they have, and then you should print out the number of donuts the user can purchase in the following format: "You can purchase # donut (s)." If the budget annot purchase anything print lid " Scanner is nooded for taking input from the cor can accumo
You'll be creating a program that will find a donut shop at the user's provided zip-code and determine the number of drinks that the user can buy with their budget. Name your program DonutShop. java. First, your program should ask the user for their desired zip code. Using a switch statement block, you should determine what donut shop is at that zip code: ● ● 33511 is Dunkin Donuts 30328 is Tim Hortons 30356 is Krispy Kreme 30211 is Sublime If the zip code doesn't match any number, then it should print out "Sorry, no shops found." and the program will end. If there's a donut shop, you should print "There is a donut shop called [name] here!" then prompt the user for their budget (integer input). Next, using an if/else conditional block and the below cutoffs, determine the number of donuts the user will be able to purchase. ● A budget between $1 to $5 (inclusive) can purchase 2 donuts A budget between $6 to $11 (inclusive) can purchase 4 donuts A budget between $12 to $20 (inclusive) can purchase 8 donuts A budget greater than $20 can purchase 16 donuts All other budgets cannot purchase anything You should ask the user to enter the number of dollars they have, and then you should print out the number of donuts the user can purchase in the following format: "You can purchase # donut (s)." If the budget annot purchase anything print lid " Scanner is nooded for taking input from the cor can accumo
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
Related questions
Question
Expert Solution
Step 1
The Complete answer in Java Programming is below:
Step by step
Solved in 3 steps with 3 images
Knowledge Booster
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.Recommended textbooks for you
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)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
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)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education