CSC 271
Homework 5

Assigned 3 Nov
Due 17 Nov

Write a C or C++ program which acts as a simple shell: it repeatedly prints a prompt, reads a command line from stdin, and executes it.

The minimal version of the program has only one built-in command, "exit", which gets you out of the program; in addition to "exit", it should be capable of running any program in the standard system paths (e.g. /bin,/usr/local/bin,etc.). You may use the "system" function to send the command to the Bourne shell for execution.


Last modified: Oct 16 2005
Stephen Bloch / sbloch@adelphi.edu