Answered step by step
Verified Expert Solution
Question
1 Approved Answer
COMP 340 - HOMEWORK #1 DUE DATE: October 5th, 2022. Submission: Email zip file to steven.pearce@ufv.ca (your code must compile). TASK: Build a simple
COMP 340 - HOMEWORK #1 DUE DATE: October 5th, 2022. Submission: Email zip file to steven.pearce@ufv.ca (your code must compile). TASK: Build a simple shell. Cite all references! Do not copy and paste code. DESCRIPTION: Write a shell program in C similar to "csh" that takes commands from the keyboard. In particular, your shell prompt must be the current time (instead of, say, % as is common in UNIX). Make it simple; that is, do not allow it to handle background processes, it can ignore the control-C key, and especially, do not design it to interpret shell scripts. You will need the following system calls: fork waitpid one of execv, execve, execvp (read the manual pages). You must NOT use the C library function "system" (you will receive a grade of zero if you do!). NOTES: This assignment is designed to get you familiar with UNIX and C. If you find that you are writing a lot of code, then something is wrong. You are to demonstrate your code in class either on your computer or the PC in the laboratory. After that, you will submit a single .ZIP, .RAR or .TAR file on my datastick that will contain: 1) A soft copy of your source code. 3) A soft copy of a report documenting the internal design of your program.
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