We went through the solution to problem #5 in class, but here is one solution for each of the other 4 problems.