How I grade Grade programming assignments and products
|[chongo's home] [Astronomy] [Mathematics] [Prime Numbers] [Programming] [Technology] [contacting Landon]|
My grading systemOn coding assignments I give to students, here is how I assign grades. It is also how I grade development efforts and products.
A few Introductory remarksHere is my grading system for assigned programs.
In this section I use the letter grade system that is in common use on parts of the US. I recognize there are many other educational grading systems, some better. Feel free to convert these grades to the grading system of your country.
This grading systems is not limited to just C programs. In fact, the system is largely language independent. And while my remarks are given in the context of Un*x like operating systems, there exist equivalent requirements for other operating systems, even those written for Windoz! :-).
While the focus of this is on source code of a program, most of it applies to products that include programs in general.
What is needed to not get an FA program that passes the well it works test is what is required to not flunk the assignment. If it doesn't work as needed according to the assignment, you get an F.
NOTE: The International Obfuscated C Code Contest was created to demonstrate, via irony, that working is not enough. IOCCC entries that do not work are rejected. IOCCC winners would get, at best, an F+, or failing grade. :-)
HINT: The Micro$oft office suite, and the individual office elements get an F+ due to the fact that they crash on a regular basis.
What is needed to get at least a D-, D or D+Assuming your program works, your program must be reasonably commented to get a D-, D or D+.
By reasonably commented, I mean useful comments that lets someone jump into the middle of your code and quickly grasp what is happening and why.
HINT: Try using code reviews by programmers not directly involved with your project or product. Good code reviews can help identify faults that would cause you to fail and get an F grade. A reasonably commented program will help code reviews understand your program and give you better code review feedback.
What is needed to get at least a C-, C or C+Assuming your program works, and is reasonably commented, your program must come with appropriate documentation to get a C-, C or C+.
By reasonable documentation I refer to things, when they are applicable, such as:
Not all of the above bullet list is applicable to every program or product. Think of this list as a general guide instead of strict requirement.
HINT: This is why Technical Publications (i.e., tech pubs) people are essential for a product release. While the basic content of much of the above mentioned bullet list may come from the developer(s), your tech pubs is needed to turn it into a coherent and useful content. If your QA does not include testing of the Tech Pubs part of your product, you product is likely incomplete. Without verified tech pubs output, I would consider your shipping product to have just an unsatisfactory passing grade of at best a D+.
What is needed to get at least a B-, B or B+Assuming your program works, and is reasonably commented, and comes with appropriate documentation, your program must be portable, testable, easy to install, and maintainable to get a B-, B or B+.
By portable, testable, easy to install , and maintainable I refer to things where they are applicable, such as:
The above list is what is needed to your program to be considered robust. And while the above list was written with Un*x like operating systems in mind, an equivalent list applies to programs and products for other operating systems.
Again, not all of the above bullet list is applicable to every program or product. For example, a program that is simple enough to be written in its entirety in one sitting might not need to be under source code control. On the other hand, if you intend to modify it, it should. Use your judgment.
HINT: Some will point out on the above bullet items related to error checking is what is needed to ensure that the program works: that without them your program is more likely to fail. Therefore you might consider system and library call error checking and the ability to warn and/or gracefully abort as what may be needed to not get an F, or failing grade.
HINT: This is why Quality Assurance (i.e., QA) is essential for a product release. Your QA cycle is not a luxury that should be squeezed to meet a deadline. Without a proper level of QA your program cannot get better than C+. In fact, it is fundamental to your program working at all and avoiding an F, or failing grade.
What is needed to get an A- or AAssuming your program works, and is reasonably commented, and comes with appropriate documentation, and is portable, testable easy to install, and maintainable, your program come with functionality and features that compel the user to ask for new and/or better features, new and/or functionality.
HINT: A well written program is one that to user likes so much that they offer make requests improvements, new and better features, etc. The author(s) of the program may not be the ones who can, or have the time to deliver on these improvements. This is one reason why open source is so important. It is harder for others to build in your success in a closed source world. Consider releasing and sharing the code under a system such as github> or SourceForge just to name two of several excellent sites for sharing code.
And in case you are wondering:
What is needed to get an A+Assuming your program works, and is reasonably commented, and comes with appropriate documentation, and your program is portable, testable, easy to install, and maintainable to get a A+ your program must be elegant.
I realize that there may not be a precise definition of an elegant program. It may be that elegance lacks clearly defined parameters. However I believe I know it when I see it. Moreover I believe that for expert programmers, the Elephant test may apply to determine what is an elegant program.
HINT: Be careful that in trying to be elegant you don't attempt to be clever and/or tricky. Winners of the International Obfuscated C Code Contest are often clever and/or tricky. But those winners would find it hard to get a passing grade because of all of the above mentioned grade requirements.
A few final remarksThe above standards apply everything from the simple "hello, world" program to very complex product systems. Sure, for the "hello, world" program some of the above elements may be overkill, but no code is too small to write well.
You may feel like slacking off when writing small programs, But good ideas tend to grow into major programs. What was a quick hack can quickly get away from you and turn into a pile of poo. By practicing good programming development with even the smallest of programs, you will gain experience by practicing. With practice these things will become easier and easier to do.
You may have been coding without best practices for years. Or you may be a beginner programmer. No programmer is too inexperienced or too advanced to start coding well.
The above grading system is by no means complete. One can certainly improve on and expand these ideas.
Yes, I know that grades such as F+ and A+ are not real grades in some systems. I include them in this essay in the spirit of a lite humorous read.
Feedback is welcome. Even feedback about typos and awkward language. I welcome you to contact me with any constructive suggestions or corrections.
A few useful and somewhat related links:
Landon Curt Noll
chongo (was here) /\oo/\
$Revision: 1.11 $ $Date: 2015/05/12 01:22:27 $