CS 101 HW5 Grading Notes 50 points total Overall: - must have name and lab section in a comment at the top (-1 point) - each function must have docstring (-2 points total) - submitted code must compile and run (-5 points) - program must produce NO OUTPUT when run, ie, when pressing green arrow in Thonny (-2 points total) - our testing script must be able to run without crashing (-3 points) GCD (prelab): - must work correctly as outlined in instructions (up to -5 points) - NO usage of input() or print() (-2 points) - must be recursive (-5 points) Stairs: - must work correctly as outlined in instructions (up to -10 points) - "levels" number of squares are drawn, level 0 square is blank (-2 points) - drawStairsScene() function provided (-5 points) - NO usage of input() or print() (-2 points) - no return statements (-1 point) isPrime: - must work correctly as outlined in instructions (up to -5 points) - only checks a limited set of numbers, NOT all numbers 2 to n (-1 point) - must be done iteratively (-5 points) - must use a for loop (-3 points) - NO usage of input() or print() (-2 points) - must work for any positive number (-2 points) printPrimes: - must work correctly as outlined in instructions (up to -5 points) - must be done iteratively (-5 points) - must use a while loop (-3 points) - must print NOT return (-2 points) - must be printed line-by-line OR single-line, comma separated (-1 for extraneous output) - NO usage of input() (-2 points) - must make use of isPrime (-3 points) GCD2: - must work correctly as outlined in instructions (up to -5 points) - NO usage of input() or print() (-2 points) - must be done iteratively (-5 points) caesar_encrypt: - must work correctly as outlined in instructions (up to -5 points) - must make use of shift_letter() (-2 points) - must be able to correctly decrypt when given a negative shift (-2 points) - NO usage of input() or print() (-2 points) firstPrimes: - must work correctly as outlined in instructions (up to -5 points) - must be done iteratively (-5 points) - must use a while loop (-3 points) - NO usage of input() or print() (-2 points) - must return a list (-3 points) factors: - must work correctly as outlined in instructions (up to -5 points) - must be done iteratively (-5 points) - must use a for loop (-3 points) - must work for any positive number (-2 points) - NO usage of input() or print() (-2 points) - must return a list (-3 points) Challenge 1 (Maze): - Up to 2 extra points if it matches our sample drawing - 2 points if drawing matches and code additions are concise - 1 point if drawing matches and much extra code was needed Challenge 2 Part 1 (leaf): - Up to 2 extra points if it matches our sample drawing Challenge 2 Part 2 (better leaf): - 1 extra point if drawing matches our sample drawing Challenge 3 (sumNested): - up to 2 extra points if solution passes all our test cases AND concisely uses isinstance() - 1 extra point if it passes all our test cases, not done concisely Testing code we will run on every submission -- to be erased before submitting (-2 points) print("GCD(24, 36) = ", GCD(24, 36)) print("GCD(64, 56) = ", GCD(64, 56)) print("isPrime(1) = ", isPrime(1)) print("isPrime(2) = ", isPrime(2)) print("isPrime(5) = ", isPrime(5)) print("isPrime(71) = ", isPrime(71)) print("isPrime(121) = ", isPrime(121)) print("isPrime(529) = ", isPrime(529)) print("printPrimes(1): ") printPrimes(1) print("printPrimes(5): ") printPrimes(5) print("GCD2(24, 36) = ", GCD2(24, 36)) print("GCD2(64, 56) = ", GCD2(64, 56)) print("caesar_encrypt('hello', 3) = ", caesar_encrypt('hello', 3)) print("caesar_encrypt('izekslfpkopnbi dpokxikce pbkcpnbpdkxpcclrp', -11) = ", caesar_encrypt('izekslfpkopnbi dpokxikce pbkcpnbpdkxpcclrp', -11)) print("firstPrimes(1) = ", firstPrimes(1)) print("firstPrimes(5) = ", firstPrimes(5)) print("firstPrimes(10) = ", firstPrimes(10)) print("factors(21) = ", factors(21)) print("factors(529) = ", factors(529)) print("factors(1337) = ", factors(1337))