Note: User the Back button to return to the previous position.
What should I do if this FAQ page does not answer my question?
If you want to use the Netscape Messenger newsreader, you should at least make the following changes:
It's useful to be able to tell at a glance what a post is likely to be about, especially when you're looking for an old post you'd like to take another look at. So in order to make this newsgroup a somewhat better tool, I'd like to ask you to be explicit in your subjects. If the subject is a specific homework problem, as many are, start by specifying exactly which problem you want to talk about (e.g. hw3p2 for homework 3, problem 2), and then a short description or a few keywords about your question. For example:
hw3p3: can we assume positive inputs?
hw4p3: what about non-letters?
hw2p3: maximum month input
... might be good titles for questions about input testing for hw3 problem 3, about what to do with non-letter inputs for hw4 problem 3, and whether you can assume that the user will enter a reasonably small number of months to project for the purposes of making your output pretty in hw2 problem 3.
If you are using a Macintosh or another machine that doesn't come with a telnet program, you can get the PennConnect CD from the Computing Resource Center in Suite 202 at Grad Tower B (aka Sansom Place West, 3650 Chesnut St.). I believe it's free or very inexpensive. Or else most of the software on that CD is available for download at this page.
That said, appendix B of your textbooks lists the sources for the textbooks libraries, and it also gives directions on how to obtain the sources electronically (these instructions are correct except that the host name in step 2 should be ftp.aw.com rather than just aw.com). Once you obtain the sources for your platform, you'll have to compile them yourself - there are no pre-built, read-to-use book libraries.
Now even once you get the libraries compiled, they will be somewhat
harder to use than the environment we're providing on eniac. In particular,
you won't have a compile script, which we wrote to hide some of the complexity
involved in using the book's libraries. In particular, you'll have to figure
out how to tell your compiler where to look for your copies of the book's
libraries and header files. How to do this depends on the particular compiler:
every compiler is different. If you're doing this
on a UNIX-like system with gcc, then reading our compile script may
help you (it's in /html/courses/cse110/compile on eniac).
Finally a word of warning: if you do work with a home compiler, it is your responsibility to make sure your code runs on eniac. All grading is done on eniac, so if it doesn't compile without warnings or errors there, it will be treated as having those warning or errors for the purposes of this course, regardless of whether it worked fine on your home machine or not.
Over disk quota on /home5, remove 497K within 7.0 days
You'll also be unable to create new files on your E: drive when you are using emacs on the PC when this happens (and emacs might not make it obvious that this is the case).
One way of fixing this is to run the command 'clean-acct' - this program will search for various common ways you can save space and ask you if you want to delete files or not interactively. If you find that you really need more space, you can run the command 'raisequota' (this will run the program clean-acct automatically, then ask you if you still need more space).
Also, you may want to add the following line to your .cshrc file (if it doesn't already exist):
limit coredumpsize 0
This will prevent the computer from generating (typically large) core
files (whatever those are [wink]).
In a minute or so after you handed in your homework, you'll get an automated
reply from the graders' account which gives a directory listing of
everything you've sent for that particular homework. Note:
Since you're sending all parts separately, you'll get an automated
reply after each part sent. After you send the last part, you
should see that the directory contains all relevant parts.
These emails are just meant to show you that your files have been turned
in successfully, and to inform you if you turned them in late. All
of the mail that you get from "Graders of CSE 110 <grade110@seas.upenn.edu>"
is automatically generated and you should not reply to them
- mail that goes to that account is generally not read by a person.
Bad programming practice means that you have written your code in such a way as to subvert some of the safety features of your programming language. This includes breaking an abstraction or otherwise bypassing the type system, inappropriately using global variables, needlessly repeating identical code, etc.
Use of disallowed tool means that while your program may work correctly, you have programmed it using functions or constructs the class was told were disallowed explicitly for this exercise, or else have used a function or construct that has not been covered in class (yet) such that you've avoided a key point of the exercise. You must get permission from a TA or instructor to use programming tools the class hasn't been taught.
The first deduction is intended to help you avoid types of programming that may have worked in your program, will likely lead to strange bugs or erratic behavior in general. The graders have been asked to point out any such problems you might have in certain homeworks.
The second deduction is meant to apply in the cases where you've done the program in a way the problem has explicitly told you not to, or if you've used a tool form later in the course without clearing it with an instructor or TA.
What happens if I have a final conflict?
If you are taking any of the following courses this semester (Spring 2001):ACCT 101, 102, 203, 703
FNCE 726
ITAL 110-140please contact your instructor. The final exam for these courses is scheduled at the same time as our final exam and we need to decide how to handle this.
If you leave out the return type of a function definition (including main), the standard C (called ANSI C) will interpret it as a function that returns int. Within the course environment, an int function definition without returning a value will issue a warning. Since in this course, you are not expected to return a value from the main function and your programs must not issue warnings, you should prefix your main function with the keyword void.
fcn()
{
int a;
if (a == 0) {
exit(0);
}
}
Note that you can accomplish both of the above cases at the same
time with something like this (the body of the while loop is deliberately
empty):
while(getchar()!='\n'){
/* eat up everything up to and including the
end of line */
}
int arr[10];
printf("%d", arr[20]);
So, check all of your array references -- esp. the ones in loops.
Now that we're using pointers, you can also get a segmentation fault by following accessing a pointer that doesn't have memory allocated for it, e.g.:
int *i;
*i = 4;
or
typedef struct {
int x;
} fooT;
fooT *stuff;
stuff->x = 3;
... will both almost certainly cause a segmentation fault. You would
need to either use malloc() or else have already created a local
variable for the pointer to point to before you attempt to follow the pointer.
scanf("%d", number);
In this case, number is integer. scanf() expects you to pass it the address of the variable you want to read an integer into. But, the writer has fogotten to use the '&' before number to give scanf the address of the variable. If the value of number happened to be 3, scanf() would try to access memory location 3, which is not accessible by normal users. The correct way to access the address of number would be to place a '&' (ampersand) before number:
scanf("%d", &number);
Another common segmentation fault occurs when you try to access an array index which is out of range. Let's say you set up an array of integers:
int integers[80];
If, in your program, you try to use an index (the number within the brackets) over 79, you will "step out of your memory bounds'', which causes a segmentation fault. To correct this, rethink your array bounds or the code that is using the array. [source: http://www.cs.bu.edu/help/unix/segmentation_fault.html]