used the useful function array_from_function
added a useful helper function
refactored problem 3
added a test to problem 3
plotting problem 3…