exercise 32 and 39 finished. Ready to commit.
corrected with endswitch() function