Cody

Solution 2004617

Submitted on 6 Nov 2019 by Weiyang Zhang
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 = [257.68]; b = [2 1 0 0 1 1 0 1 0 1 1 3]; out = makingChange(a); assert(isequal(out(:), b(:)))

a = 257.6810 a = 157.6810 a = 57.6810 a = 7.6810 a = 2.6810 a = 0.6810 a = 0.1810 a = 0.0810 a = 0.0310 a = 0.0210 a = 0.0110 a = 1.0000e-03 b = 2 1 0 0 1 1 0 1 0 1 1 3

2   Pass
a = [135.01]; b = [1 0 1 1 1 0 0 0 0 0 0 1]; out = makingChange(a); assert(isequal(out(:), b(:)))

a = 135.0110 a = 35.0110 a = 15.0110 a = 5.0110 a = 0.0110 a = 1.0000e-03 b = 1 0 1 1 1 0 0 0 0 0 0 1

3   Pass
a = [10035.99]; b = [100 0 1 1 1 0 0 1 1 2 0 4]; out = makingChange(a); assert(isequal(out(:), b(:)))

a = 1.0036e+04 a = 9.9360e+03 a = 9.8360e+03 a = 9.7360e+03 a = 9.6360e+03 a = 9.5360e+03 a = 9.4360e+03 a = 9.3360e+03 a = 9.2360e+03 a = 9.1360e+03 a = 9.0360e+03 a = 8.9360e+03 a = 8.8360e+03 a = 8.7360e+03 a = 8.6360e+03 a = 8.5360e+03 a = 8.4360e+03 a = 8.3360e+03 a = 8.2360e+03 a = 8.1360e+03 a = 8.0360e+03 a = 7.9360e+03 a = 7.8360e+03 a = 7.7360e+03 a = 7.6360e+03 a = 7.5360e+03 a = 7.4360e+03 a = 7.3360e+03 a = 7.2360e+03 a = 7.1360e+03 a = 7.0360e+03 a = 6.9360e+03 a = 6.8360e+03 a = 6.7360e+03 a = 6.6360e+03 a = 6.5360e+03 a = 6.4360e+03 a = 6.3360e+03 a = 6.2360e+03 a = 6.1360e+03 a = 6.0360e+03 a = 5.9360e+03 a = 5.8360e+03 a = 5.7360e+03 a = 5.6360e+03 a = 5.5360e+03 a = 5.4360e+03 a = 5.3360e+03 a = 5.2360e+03 a = 5.1360e+03 a = 5.0360e+03 a = 4.9360e+03 a = 4.8360e+03 a = 4.7360e+03 a = 4.6360e+03 a = 4.5360e+03 a = 4.4360e+03 a = 4.3360e+03 a = 4.2360e+03 a = 4.1360e+03 a = 4.0360e+03 a = 3.9360e+03 a = 3.8360e+03 a = 3.7360e+03 a = 3.6360e+03 a = 3.5360e+03 a = 3.4360e+03 a = 3.3360e+03 a = 3.2360e+03 a = 3.1360e+03 a = 3.0360e+03 a = 2.9360e+03 a = 2.8360e+03 a = 2.7360e+03 a = 2.6360e+03 a = 2.5360e+03 a = 2.4360e+03 a = 2.3360e+03 a = 2.2360e+03 a = 2.1360e+03 a = 2.0360e+03 a = 1.9360e+03 a = 1.8360e+03 a = 1.7360e+03 a = 1.6360e+03 a = 1.5360e+03 a = 1.4360e+03 a = 1.3360e+03 a = 1.2360e+03 a = 1.1360e+03 a = 1.0360e+03 a = 935.9910 a = 835.9910 a = 735.9910 a = 635.9910 a = 535.9910 a = 435.9910 a = 335.9910 a = 235.9910 a = 135.9910 a = 35.9910 a = 15.9910 a = 5.9910 a = 0.9910 a = 0.4910 a = 0.2410 a = 0.1410 a = 0.0410 a = 0.0310 a = 0.0210 a = 0.0110 a = 1.0000e-03 b = 100 0 1 1 1 0 0 1 1 2 0 4