Cody

Solution 1844473

Submitted on 10 Jun 2019 by Monika Phadnis
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

Test Suite

Test Status Code Input and Output
1   Pass
a = 1; b = 2; out = sumDigits(a); assert(isequal(out, b))

tm = int16 2 sum = int16 2 num = int16 0

2   Pass
a = 10; b = 7; out = sumDigits(a); assert(isequal(out, b))

tm = int16 4 sum = int16 4 num = int16 102 tm = int16 2 sum = int16 6 num = int16 10 tm = int16 0 sum = int16 6 num = int16 1 tm = int16 1 sum = int16 7 num = int16 0

3   Pass
a = 16; b = 25; out = sumDigits(a); assert(isequal(out, b))

tm = int16 7 sum = int16 7 num = int16 3276 tm = int16 6 sum = int16 13 num = int16 327 tm = int16 7 sum = int16 20 num = int16 32 tm = int16 2 sum = int16 22 num = int16 3 tm = int16 3 sum = int16 25 num = int16 0