P1 G.C.

advertisement
Program #1 Grading Criteria
Grading for Data: 1 points for satisfying each of the following:
First line of file as a single positive integer equal to the number of cases
Each subsequent line has 2 tokens on it
Each token is a positive integer that doesn’t start with 0, or is 0.
0x0
0 x digit
0 x multi-digit
digit x 0
multi-digit x 0
digit x digit – no carry
digit x digit – carry
multi-digit x digit – no-carry
digit x multi-digit – no-carry
multi-digit x digit – carry
digit x multi-digit – carry
multi-digit x multi-digit same number of digits – no carry
multi-digit x multi-digit same number of digits – carry
multi-digit x multi-digit different number of digits – no carry
multi-digit x multi-digit different number of digits – carry
smaller # of digits x larger number of digits
larger# of digits x smaller # of digits
Multiplication between two numbers, both with 50 or more digits
Multiplication between two numbers, both with 10000 digits exactly
Multiplication between two numbers, both with 10000 digits exactly and multiple carries
2 free points for a submission
Implementation Restrictions and code points (15 pts)
Specs for the multiply function are followed (5 pt)
Follows I/O spec properly (2 pts)
Properly allocates memory dynamically (4 pts)
Properly frees the dynamically allocated memory (4 pts)
Feel free to award partial credit in each category.
Execution Points (50 pts)
2 pts per case, max of 40 if the program crashes at all. Feel free to give partial credit on
cases if they’re pretty close. Also, feel free to take off a set number of points for a
systemic error instead of counting off for each case it makes incorrect.
Style Points (10 pts)
Header comment w/name, program, date – 1 pts
Appropriate variable names – 1 pts
Appropriate use of white space – 2 pts
Appropriate indenting – 2 pts
Comments in code – 4 pts
Download