CIS 432/532 Introduction
to Computer Networks
Winter 2001
Program
#1 FAQ
- Q: Can my client print OK after the user types "close:"?
A: No. The assignment states that you should not print the server's response
to a close command.
- Q: What if the user types "close:a bunch of junk"?
A: The assignment doesn't specify the behavior here. You can handle this any
way that you want (either accepting it as a valid close command or rejecting
it as an invalid command). I will NOT be checking this when I grade programs.
As long as the regular "close:" command works, I will be happy.
- Q: What if the user types "UPPER:uppercase this"?
A: This is an invalid command. The commands themselves must be typed in lowercase.
- Q: Should I count a newline when I process the "count:"
command?
A: No.
- Q: Should I count a spaces when I process the "count:"
command?
A: Yes.
- Q: Do I need to handle the case where the arguments
are listed in a different order on the command line?
A: Yes. The sample code for C shows you how to do this in C.
- Q: What if the user doesn't type any arguments on the
command line? Should I use some defaults or should I print an error message?
A: Print an error message.
- Q: What is the equivalent of Java's "IndexOf"
in C?
A: Use the strchr() system call.
- Q: Does the user have to type a complete host name,
like ix.cs.uoregon.edu, or can the user just type "ix"?
A: The user should be able to use either one. The host lookup routines on
a UNIX machine can handle both cases.