about | help | code help+videos | done | prefs |
specialSumThree
Given 3 int values, a b c, return their sum. However, if any of the values is a teen -- in the range 13..19 inclusive -- then that value counts as 0. Also, if all three int values are equal, then return 0. specialSumThree(1, 2, 3) → 6 specialSumThree(13, 5, 10) → 15 specialSumThree(4, 4, 4) → 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: 100
Copyright Nick Parlante 2017 - privacy