about | help | code help+videos | done | prefs |
Write a method that returns the sum of the three input parameters. Except this is a "funny sum" which means that if ANY of the three numbers match, return a value of 0 instead of the sum. For example, input values of 5, 1, and 2 would return an 8. However input values of 3, 1, and 3 would return zero since two of the numbers are the same. Also return zero if all three numbers are the same. Look at the test data for examples. dec16_2019_APP1SLHL_funnySum(5, 6, 4) → 15 dec16_2019_APP1SLHL_funnySum(3, 77, 3) → 0 dec16_2019_APP1SLHL_funnySum(8, 8, 3) → 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: 290
Copyright Nick Parlante 2017 - privacy