ulrail.gif

Quiz 1 Grading Guidelines

  ur-2c.gif urrail.gif
blrail-nonavbar.gif

Home | Resources | Homeworks | Exams
Lectures | Labs | Contacts | Submit | TAs

br-2a.gif   br-2c.gif brrail.gif
spacer.gif spacer.gif

These are the instructions given to the graders when they graded Quiz 1.

If the program does not compile and/or not run, you need to look at the code, and manually trace it to find out why.  Don't take points off if it doesn't compile, though -- the system does that automatically.

Sample Output

The output should be what's listed below -- there is only one execution run.  The input provided was 1, 1, 2, 2, 2, 2.  The text in red is what was input to the program.  The text in green is optional -- they don't have to have it.  Note that the rectangle is dimensions 2x2, and the upper-left corner is at (1,1).  It then is moved so that it's upper-left corner is at (2,2), and lastly it is expanded by 2 in each direction, so that the final dimensions are 4x4.

Rectangle manipulation

Enter four values for the rectangle: x, y, width, and height
1
1
2
2
 +--------------------------------------------------------------------------+
 |                                                                          |
 |  +--+                                                                    |
 |  +--+                                                                    |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 +--------------------------------------------------------------------------+

Enter two more integer values
2
2
Rectangle at 2, 2:
 +--------------------------------------------------------------------------+
 |                                                                          |
 |                                                                          |
 |    +--+                                                                  |
 |    +--+                                                                  |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 +--------------------------------------------------------------------------+

Rectangle grown by 2, 2:
 +--------------------------------------------------------------------------+
 |                                                                          |
 |                                                                          |
 |    +------+                                                              |
 |    |      |                                                              |
 |    |      |                                                              |
 |    +------+                                                              |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 |                                                                          |
 +--------------------------------------------------------------------------+

Point Distribution

  • 15 points: Good programming practices
    They only had to include a few of these (and, due to a typo, name and e-mail ID was not one of them)
    • -5 for excessively long lines in code
    • -5 for excessive whitespace (more than 2-3 lines)
    • -2 for each misleading comments
    • -5 for bad indentation
    • -5 for bad variable names (but they can use r for the Rectangle name)
    • -5 for making one or more variables (including the Rectangle) final
       
  • 15 points: Integer input (and Scanner creation)
    • -10 if they obtain the input in the wrong order, but grade the rest of the quiz as if the input was provided in the order they desired
    • -5 if they declare multiple Scanner objects (program will encounter a run-time exception if this occurs)
    • -10 if they use BufferedReader and InputStream instead of Scanner
    • -10 if they use Scanner.create() rather than new Scanner()
    • -15 if they don't ask for input (even if they created a Scanner object)
    • -7 if they ask for more input than required
       
  • 15 points: Display of rectangle
    • -10 for each time it was not printed (should print it three times)
    • 2/3 credit (round up if 0.5 or above) for this part if it's correct but commented out
       
  • 15 points: Creation of rectangle
    • -5 for a minor error
    • -10 for a big error
    • -15 for getting it completely wrong
    • 2/3 credit (round up if 0.5 or above) for this part if it's correct but commented out
       
  • 20 points: setLocation() call
    • -5 for a minor error
    • -10 for a big error
    • -15 for getting it completely wrong
    • -10 if they create a new rectangle for this part (they should use the old one)
    • 2/3 credit (round up if 0.5 or above) for this part if it's correct but commented out
       
  • 20 points: grow() call
    • -5 for a minor error
    • -10 for a big error
    • -15 for getting it completely wrong
    • Full credit if they use resize() to achieve the same effect (they should use resize() the way it should logically be used)
    • -10 if they use resize() for this, but do it wrong
    • -10 if they create a new rectangle for this part (they should use the old one)
    • 2/3 credit (round up if 0.5 or above) for this part if it's correct but commented out

 

spacer.gif
spacer.gif footer-middle.gif spacer.gif