Introduction to Computer Science I by James Tam

Return to the course web page

CPSC 231: Assignment 3 (Marking Key)

    Your score Max score

Coding style (marks independent of program functionality)

   
 
  • Appropriate use of white space (source code)
  2
 
  • Self-documenting variable and constant names.
  3
 
  • Use of named constants as appropriate
  1
 
  • Boolean and mathematical expressions are simple and easy to read
  3
 
  • Minimum of 3 functions employed
  3
 
  • Each function implements one well defined task
  4
 
  • Functions don't exceed one screen size in length ~20 - 30 lines
  2
 
  • Global variables employed
  -4
 

Sub total

 

18

Documentation (marks independent of program functionality)

   
 
  • Header documentation includes name and tutorial section
  1
 
  • Header documentation contains description of program.
  1
 
  • Some form of versioning system is demonstrated in the header documentation
  1
 
  • Each function is documented (similar to documentation for the entire program but applies only to that function)
  3
 

Sub total

 

6

Functionality (only qualify for these marks if the program runs)

   
  Prompts for expression   1
  Displays the original expression at same time as displaying the result   1
  Displays a result based that's somehow based on the expression (not hard-coded)   2
  Can correctly calculate result for 2 operands, 1 operations (all four)   6
  Can correctly calculate result for 3 operands, 2 operations (all four)   4
  Can correctly determine the order of operation (only applicable if program can handle 2 operators)   4
  Can properly handle real number input and can detect erroneous real input   4
  Clear and helpful error messages/prevention   2
  Determines if operator is valid   2
  Can handle leading/trailing white space   2
  Sub total   28
       

OVERALL ASSIGNMENT TOTAL (Letter grade)

 

52

 

Raw score Letter
51 - 52 A
48 - 50 A-
44 - 47 B+
41 - 43 B
38 - 40 B-
35 - 37 C+
32 - 34 C
28 - 31 C-
24 - 27 D+
15 - 23 D
0 - 14 F