Sunday, December 13, 2009 1:22 AM,
A student writes. In fact, this is the second almost identical letter from a different student so I am sharing this one with you all. Dear Dr. Patt, Hi. Sorry to bother you while you are busy on your trip. I talked with Arvind about my grade for program 4 and he suggested me to talk with you instead. I got an 80 on my nim program because I did not cleared all the registers before it runs. I do not mind being interrupted on my trip. I realize you are agonizing over your grade in the course. However, ... I know that you have mentioned this in class, In fact, I made it very clear in class on more than one occasion that you can not assume anything about the initial value of a location. Therefore, you had better written to it before you read from it. Every location that has not been initialized can be assumed to be in some random state. I not only said it in class, I also wrote more than one program in class where I spelled it out for you - if I want to use a register (like a counter, for example), I need to initialize it before I use it. AND the code I wrote in class did just that. Given this, I think 20% penalty for not initializing a variable is an appropriate penalty. but this test case just did not pop up in my head while I was doing my program, Clearly not. -20 points. and when I went over the instruction sheet of the program, this test case is not written on there. Indeed, all test cases should not be. ...for good reason. You are supposed to write a program that works on all tests, not just a set that I give you ahead of time. Therefore, I assumed that the registers/memories is not going to be loaded with stuff before the program runs. Bad assumption, based on what I emphasized in class. I truely hope than I can get a regrade for this program since I think 20 points is too much. I do not believe a regrade is appropriate in this case. Also, I want to suggest that it would be better to write down all the test cases for the programs on the instruction sheets in the future since the students would know what they are going to expect. Sorry, I can not take your advice. Have you ever had an instructor do that? It would be bad instruction if he/she did. Then you would not have to write a program that works, you would only have to write a program that works on the pre-established cases. Such a program would never see the light of day since programs, if they are to be useful must run correctly on all input data, not just on a set of samples that were thought about in advance. Again, have you ever had a course where the instructor gave you all the test cases ahead of time? If so, and if he was supposed to be teaching serious students to behave seriously, he should be fired. Thank you Dr. Patt. Good night. Best regard, <<name withheld to protect the student overly concerned about his grades>> Hope the above helps. Good luck on the final exam. Yale Patt