Answered step by step
Verified Expert Solution
Question
1 Approved Answer
In this challenge, you will work with redirection to create test inputs for several different programs. Write the output of the command is - la
In this challenge, you will work with redirection to create test inputs for several different programs. Write the output of the command is la binto the fileusercodebindirdat HINT: notice has a slash on the end, this is important otherwise it will not list the directory's contents Use printf to create a list of numbers that are new line delimited each value is on a new line in the file usercodenumbers txt Example: printf usercodenumberstxt The output should look like: We need to sort the fileusercodejumbled dat and write the sorted version to usercodesorted dat a We can sort the contents of the file using the sort command, if unsure of how to use the sort command, try sort help b The sorted results must be ordered in numerical order not string order sort has an argument you can provide for this c Without thine numeric the results might look like this $ cat usercodejumbleddat I sort Create a file usercodereversed dat where theusercodejumbled dat is sorted and then reverse the number on each line and save the results into usercodereversed dat, to do this use the command above but add rev usercodereversed
In this challenge, you will work with redirection to create test inputs for several different programs.
Write the output of the command is la binto the fileusercodebindirdat
HINT: notice has a slash on the end, this is important otherwise it will not list the directory's contents
Use printf to create a list of numbers that are new line delimited each value is on a new line in the file usercodenumbers txt
Example:
printf
usercodenumberstxt
The output should look like:
We need to sort the fileusercodejumbled dat and write the sorted version to usercodesorted dat
a We can sort the contents of the file using the sort command, if unsure of how to use the sort command, try sort help
b The sorted results must be ordered in numerical order not string order sort has an argument you can provide for this
c Without thine numeric the results might look like this
$ cat usercodejumbleddat I sort
Create a file usercodereversed dat where theusercodejumbled dat is sorted and then reverse the number on each line and save the results into usercodereversed dat, to do this use the command above but add rev usercodereversed
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started