Solution 14

Algorithm programmed, holding very large values.