Added solution to problems 14, 15, 18, 25 and 39