about | help | code help+videos | done | prefs |
Write a method that finds the greatest difference between any two numbers in an array of integers. Note that the array could have just one number or could even be empty. In both of these cases return zero. smaugGreatestDifference([-30, -33, -40, -31, -35]) → 10 smaugGreatestDifference([5, 2, 17, 6, 15]) → 15 smaugGreatestDifference([7]) → 0 ...Save, Compile, Run (ctrl-enter) |
Progress graphs:
Your progress graph for this problem
Random user progress graph for this problem
Random Epic Progress Graph
Difficulty: 260
Copyright Nick Parlante 2017 - privacy