CIT 591 Assignment 9: Grading the Short Token Counter
Fall 2004, David Matuszek

Grading:

In an attempt to make a "kinder, gentler" grading scheme for the final project, I've revised the grading scheme as follows:

  1. All bonuses will remain as originally specified.
  2. Any program with a total (non-comment) token count below 3000 will receive full credit (100 points)--if it works perfectly.
  3. Programs with more than 3000 tokens will have deductions as before (95, 90, 85, ..., 50).

I believe this scheme will not result in lower grades for anyone on this final project, and it reduces the burden for those who have no interest in a competition.

However, please bear in mind that your program must pass all my JUnit tests or you will receive no credit for it. If you think there is an error or omission in my JUnit tests, please let me know as soon as possible. Also, your program should meet all style criteria that don't affect token counts (such as proper indentation and good variable names) and must be reasonably easy to use.

Token counts:

I've been asked how many tokens my own program takes. Here are my counts:

  DataSource StringDataSource FileDataSource JavaTokenCounter Totals
Names
4
38
82
645
769
Keywords
5
26
42
410
483
Characters
0
0
2
65
67
Integers
0
4
1
39
44
Reals
0
0
0
0
0
Strings
0
2
1
99
102
Operators
0
21
34
307
362
Punctuation
8
57
99
1141
1305
C-style comments
0
0
1
1
2
Javadoc comments
3
4
5
23
35
End-of-line comments
0
0
0
27
27
Total comments
3
4
6
51
64
Total non-comments
17
148
261
2706
3132
Totals
20
152
267
2757
3196

Note that my own program is over 3000 non-comment tokens. However,

I do count myself as a good programmer (meaning, among other things, that I don't do any more work than necessary) so my program is probably one of the shortest; but all the student programs I've looked at are within a few hundred tokens of this, so 3000 ought to be a perfectly reasonable goal.