Menu
support@nursinghomework.org
+1 714-215-3097

(Solved) : Trying Write Bash Script Take One Arguments Calculates Wind Chill Temperature Given Air Te Q35622665

I am trying to write a BASH script that can take one or morearguments and calculates the wind-chill temperature given the airtemperature and wind speed. Specifically, I am just trying tofigure out how to use the getopt utility to parseand accept any of the following command line arguments.Note: this inquiry is to seek merely the functionalimplementation of the getopt utility in this scenario,given that there are several options the user should be able toenter in to the command line and receive a response according totheir request.

ArgumentOptional UserInput?DescriptionInformation–airtemp=<temp>NoThe outside air temperature (in Fahrenheitby default) as a integer.Uses –cin argument for Celsiusinput.-c or –coutYesDisplay wind-chill in Celsius rather thanFahrenheit.Fahrenheit output is the default.–cinYesThe –airtemp value is in Celsius ratherthan Fahrenheit.–file=<filename>YesWrite all output to the specified filerather than the command line.Only store answer if -q or –quiet isused.-h or –helpYesDisplay the help message.Describes the intended purpose of and thevalid commands for the script.-q or –quietYesDo not display anything except the answerin the output.Displays only the result of thecalculation when -q or –quiet is added on the end of thecommand-line argument.-v or –versionYesDisplay the script name and versioninformation.Displays the version, author, ect–velocity=<speed>No

The wind speed as a integer.

Leave a Reply

Your email address will not be published. Required fields are marked *