about | help | code help+videos | done | prefs |
Given two positive integers, n1 and n2, in ascending order, return the sum of the right-most digits of all the numbers between n1 and n2 (inclusive). For example, if n1 = 37 and n2 = 39, the method should return 24 because the right most digits of the numbers between 37 and 39 are 7, 8,and 9. getRighty(37, 39) → 24 getRighty(1, 3) → 6 getRighty(61, 63) → 6 ...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: 299 Post-solution available
Copyright Nick Parlante 2017 - privacy