Consolidate and Abstract Problem 2

--abstract into two functions for ease of reading
--abstract upper limit into function call, not hard coded
--both functions now properly return results
--starting allNums array should work now