Cleaned up if-statements used for outputting grades