Write a shell script called numopt

Assignment Help Basic Computer Science
Reference no: EM132186062

1. Write a shell script called numopt.sh to accomplish the following

· Prompt users to enter two number

· Prompt users to enter an operator: 1, 2, or 3

If users enter 1, display the sum of the two numbers

If users enter 2, display the difference of the two numbers

If users enter 3, display the product of the two numbers

If user enter any other numbers, display an invalid input message

2. Write a shell script called colorcode.sh that

· Asks users to enter a color code: R, Y, or G

o If users enter the code R, display the message "Stop, it is others' way."

o If users enter the code Y, display the message "Get ready, your lane will be ready shortly."

o If users enter the code G, display the message "Go ahead. It is your turn."

o If users enter anything else, display the message "Invalid code."

3. Write a shell script called agerange,sh that

· Asks a user to enter his or her age, then display a corresponding message based on the following decision table

If

Message

Less than 20 or greater than 50

Your age is out of range

20 - 30

You are in your 20s

30 - 40

You are in your 30s

40 - 50

You are in your 40s

4. Write a shell script called vowel.sh that

· asks users to enter a letter

o If the letter is a vowel, tells the user the letter is a vowel.

o If the letter is a consonant, tells the user the letter is a consonant.

o If the letter is anything else, tells the user the letter is invalid.

Hint: try to use case statement.

Reference no: EM132186062

Questions Cloud

Operations management process strategies are process focus : Four Operations Management process strategies are Process Focus, Repetitive Focus, Product Focus, and Mass Customization.
How you believe the program will help you achieve your goals : Describe the purpose of the Bachelor of Science in Health Administration (BSHA) program. Describe how you believe this program will help you achieve your goals.
Discuss the firm competitive and supply chain strategies : BUS 4843 SUPPLY CHAIN STRATEGY AND MANAGEMENT PROJECT - Briefly discuss the firm's competitive and supply chain strategies
What is network address translation : What is Network Address Translation (NAT)? Why would a company utilize it? Would it be more typical for a small, medium, or large company to use NAT?
Write a shell script called numopt : 1. Write a shell script called numopt.sh to accomplish the following
Determine the length of bursts of zero : Write a program to determine the length of bursts of zero's in a list of N numbers stored in an List. The program should record the length of the bursts of zero
Accountable care organizations may require organizational : Accountable care organizations may require organizational structures that
Describe how the company was breached : Read the NPR article titled "Uber Pays $148 Million Over Yearlong Cover-up of Data Breach" which can be found at Uber_Breach.
Positional bargaining approach-hold fast to store policy : Offer your opinion on whether or not Joe should take a positional bargaining approach and hold fast to the store’s policy.

Reviews

Write a Review

Basic Computer Science Questions & Answers

  Identifies the cost of computer

identifies the cost of computer components to configure a computer system (including all peripheral devices where needed) for use in one of the following four situations:

  Input devices

Compare how the gestures data is generated and represented for interpretation in each of the following input devices. In your comparison, consider the data formats (radio waves, electrical signal, sound, etc.), device drivers, operating systems suppo..

  Cores on computer systems

Assignment : Cores on Computer Systems:  Differentiate between multiprocessor systems and many-core systems in terms of power efficiency, cost benefit analysis, instructions processing efficiency, and packaging form factors.

  Prepare an annual budget in an excel spreadsheet

Prepare working solutions in Excel that will manage the annual budget

  Write a research paper in relation to a software design

Research paper in relation to a Software Design related topic

  Describe the forest, domain, ou, and trust configuration

Describe the forest, domain, OU, and trust configuration for Bluesky. Include a chart or diagram of the current configuration. Currently Bluesky has a single domain and default OU structure.

  Construct a truth table for the boolean expression

Construct a truth table for the Boolean expressions ABC + A'B'C' ABC + AB'C' + A'B'C' A(BC' + B'C)

  Evaluate the cost of materials

Evaluate the cost of materials

  The marie simulator

Depending on how comfortable you are with using the MARIE simulator after reading

  What is the main advantage of using master pages

What is the main advantage of using master pages. Explain the purpose and advantage of using styles.

  Describe the three fundamental models of distributed systems

Explain the two approaches to packet delivery by the network layer in Distributed Systems. Describe the three fundamental models of Distributed Systems

  Distinguish between caching and buffering

Distinguish between caching and buffering The failure model defines the ways in which failure may occur in order to provide an understanding of the effects of failure. Give one type of failure with a brief description of the failure

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd