Test | Status | Code Input and Output |
---|---|---|
1 | Pass |
x = 1:10;
y_correct = {'01';'02';'03';'04';'05';'06';'07';'08';'09';'10'};
assert(isequal(zeroPadding(x),y_correct))
|
2 | Pass |
x = 1:4;
y_correct = {'1';'2';'3';'4'};
assert(isequal(zeroPadding(x),y_correct))
|
3 | Pass |
x = 90:100;
y_correct = {'090';'091';'092';'093';'094';'095';'096';'097';'098';'099';'100'};
assert(isequal(zeroPadding(x),y_correct))
|
4 | Pass |
x = [1 4 42 100 7400 99 301 2];
y_correct = {'0001';'0004';'0042';'0100';'7400';'0099';'0301';'0002'};
assert(isequal(zeroPadding(x),y_correct))
|
17214 Solvers
1421 Solvers
Area of an equilateral triangle
2759 Solvers
128 Solvers
444 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!