subject

Assume that an int variable age has been given a value. assume further that the user has just been presented with the following menu: s: hangar steak, red potatoes, asparagus t: whole trout, long rice, brussel sprouts b: cheddar cheeseburger, steak fries, cole slaw (yes, this menu really is a menu! ) write some code that reads the string (s or t or b) that the user types in into a variable choice and prints out a recommended accompanying drink as follows: if the value of age is 21 or lower, the recommendation is "vegetable juice" for steak, "cranberry juice" for trout, and "soda" for the burger. otherwise, the recommendations are "cabernet", "chardonnay", and "ipa" for steak, trout, and burger respectively. regardless of the value of age, your code should print "invalid menu selection" if the character read into choice was not s or t or b.

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 00:50
Representa os dados de um banco de dados como uma coleç? o de tabelas constituídas por um conjunto de atributos, que definem as propriedades ou características relevantes da entidade que representam. marque a alternativa que representa o modelo descrito no enunciado. escolha uma:
Answers: 3
question
Computers and Technology, 25.06.2019 03:00
Between 1932 and 1938, chester carlson developed a process that enabled a "picture" of a document to be taken and then have it reproduced on another
Answers: 1
question
Computers and Technology, 25.06.2019 05:00
The ratio of men to women in a certain factory is 3 to 4 .there are 210 men.how many workers are there?
Answers: 2
question
Computers and Technology, 26.06.2019 03:50
4. the arduino uno analog inputs range is limited to how many bits? a. 8 b. 10 c. 12 d. 16
Answers: 1
You know the right answer?
Assume that an int variable age has been given a value. assume further that the user has just been p...
Questions
Questions on the website: 13722360