Completed assignments

Prime check could be extended by adding an array that stores primes to
increase speed like
http://www.mkyong.com/java/how-to-determine-a-prime-number-in-java/