UMBC CMSC 201, Computer Science I, Fall 1995
     Sections 0101, 0102, 0103 and Honors
 Project 1 Comments
 New Announcement: 
   Please please please, do not use anything other than the 
   mail2chang program to turn in your project.
   
   This is very important for the orderly submission of projects
   for such a large class. Unlike the other commands which I have
   asked you to copy (e.g., cc201, lynx201, etc) which saves 
   you typing, the mail2chang command saves me
   typing.  Using the mail2chang command triggers a mail filter
   program which automatically sorts your project to the correct directory,
   generates a response and starts the "cheat-checker" program.
   So, even if you have no trouble using email, it is imperative that
   you use mail2chang.
 Announcements:
   Please put your name somewhere in the beginning of your program
   before you submit it.  (We can still figure out who you are, but 
   this helps.)
   
   If you haven't been able to copy the "201" commands to your directory
   yet, you are really behind.  Read through the 
   instructions.
   If you are still having trouble, get someone to help you.  Yes, it 
   means you have to do this on campus.
   
   If you haven't played with your UNIX account yet, you are 
   really really behind.  
   Plan on spending a lot of time in front of the computer this week.
Questions and Comments (and some answers)
 
In this section, we have some questions and comments from the students.
As usual, names have been withheld to protect the innocent and the
questions have been edited for spelling and grammar.
  -   Prof. Chang,
  
 - 
  I copied the mail2chang command to my bin directory
  but when I issue the mail2chang command, UNIX says that
  the command was not found.  I looked in the bin directory
  and the mail2chang command is really there.
  
 
 -   Dear Student, 
 - 
  As before, if you copy a command to your bin directory, UNIX does not
  know it is there until you either log out and log back in, or you 
  issue the rehash command.  So, do one of these and the command should
  be available.   (See Copying the "201"
  commands".)
 
  -   Prof. Chang,
  
 - 
  After sending my project to you I cannot access my files without the 
  "ready to mail the project " program coming up.  I cannot run my
  programs.  Every time I want to, it asks me if I want to mail the project 
  to you.  How do I get rid of that?
  
 
 -   Dear Frequent Mailer, 
 - 
  It seems you have screwed-up your UNIX account in a bizarre way.
  I am not sure what you mean by "access" your files.  Does it happen
  when you issue the "ls" or "vi" commands?  Most likely you have over-written
  some file with the mail2chang command.  Get a knowledgeable
  person (me, a TA, a Help Center tutor or a UNIX consultant) to fix it
  for you.
 
  -   Prof. Chang,
  
 - 
  I accidentally sent you the wrong file.  
  Should I send you the right one?
  
 
 -   Dear Student,  
 - 
  Yes, just run the mail2chang command again. 
  The new file will replace the old one.
  (Actually, I do keep a copy of every submission.  We will grade the
  newest submission.  So, if you sent something embarassing, you have
  to ask me to delete it explicitly.)
 
  -   Prof. Chang,
  
 - 
  I am having trouble compiling my program.  I type in the command
  
     cc201 project1 
  
  and the response is 
  
     Object file format error in: project 1: bad file magic number
  
  What does that mean?  I saved my C program as "project1".
   
 -   Dear Student,  
 - 
  The file name for C source code must end with ".c".  So, rename your
  file as project1.c by issuing the command:
  
    mv project1 project1.c
  
  Then, you should be able to compile your program.
 
  -   Prof. Chang,
  
 - 
  Would you consider two break statements in one while loop
  a bad programing style?
  
  The reason I am asking is because I've looked through all the examples 
  in the textbook and I haven't found any which includes two breaks.
  I only found it true for switch statements.
  
 
 -   Oh Stylish one,  
 - 
  Yes, if you want to use two break statements in a while loop, that's fine.
  The while loop for Project 1 should be  short enough, it would not cause
  any confusion.  The break statements for
  switch statements are quite different.  We will cover break
  statements very soon.
 
  -   Prof. Chang,
  
 - 
   Looking at this Project 1 craps program, it seems that we would 
   need some command that generates random numbers.  I looked in the book 
   and tried what they had but I could not get it to work.  Could you please 
   tell me what commands to use to make random numbers in C?  
							
  
 
 -   Dear Student,  
 - 
   No, don't use random numbers.  Just have the user type in the result 
   of the dice roll.  You can play with random numbers later.
 
Last Modified: 
Wed Sep 20 14:35:53 EDT 1995
Richard Chang, chang@gl.umbc.edu