Question: A Simple Shell to run One Command with File Redirection ( < input, > output, >> append). Design and implement a simple shell program to
A Simple Shell to run One Command with File Redirection (< input, > output, >> append).
Design and implement a simple shell program to handle "one command" with file redirection.
For example (and for test cases)
1. ls > part2out1.txt
2. wc < part2out1.txt
3. date > part2out2.txt
4. ls -1 >> part2out2.txt
5. wc < part2out2.txt >> part2out3.txt
6. whoami
7. date
Provide a Makefile file to compile your program.
Your Program Name: a3p2redir1.c
Part 2. Task2.
Two Commands in Pipe, with File Redirection (< input, > output, >> append).
Design and implement a simple shell program to handle "two commands in pipe" with file redirection.
For example (and for test cases),
1. ls | sort > part3out1.txt
2. cat < part3out1.txt | wc > part3out2.txt
3. wc < part3out2.txt | cat part3out2.txt
4. wc < out2.txt > out3.txt
5. whoami
6. date
Provide a Makefile file to compile your program.
Your Program Name: a3p3redir2.c
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
