Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Scripting Language sygwin64 bash PLEASE DO NOT PUT CODE IN JAVA THIS IS BASH SCRIPT 3. Write a bash script (It must be a script

Scripting Language sygwin64 bash

PLEASE DO NOT PUT CODE IN JAVA THIS IS BASH SCRIPT

3. Write a bash script (It must be a script file and not command line output) to create a nested if statement to name the food Mr. Smith is supposed eat in a given day.

a. First your script prompt for: Mr. Smith's food eating schedule...

Enter Sunday, Monday, Tuesday, Wednesday, Thursday, Friday or Saturday:

(User enters any of the days from the list above)

b. Based on the input value, the food Mr. Smith eats is displayed as below:

Mr. Smith's food eating schedule...

Enter Sunday, Monday, Tuesday, Wednesday, Thursday, Friday or Saturday: Tuesday

On Tuesday you must eat Fruit

Note: If the user enters a unknown day, print a undefined as follows:

Mr. Smith's food eating schedule...

Enter Sunday, Monday, Tuesday, Wednesday, Thursday, Friday or Saturday: nomday

On nomday you must eat undefined

Data: Here is Mr. Smiths food schedule:

Sunday = Bread

Monday = Salad

Tuesday = Fruit

Wednesday = Pizza

Thursday = Pasta

Friday = Rice

Saturday = Fajita

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Modeling And Design

Authors: Toby J. Teorey, Sam S. Lightstone, Tom Nadeau, H.V. Jagadish

5th Edition

0123820200, 978-0123820204

More Books

Students also viewed these Databases questions

Question

=+ d. a professor deciding how much to prepare for class

Answered: 1 week ago