Completed tests for finding average of array, generating elements until more than 5, converting array to hash