This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.
Test | Status | Code Input and Output |
---|---|---|
1 | Pass |
%%
x = single(1.25);
y_correct = '00111111101000000000000000000000';
assert(isequal(single2bin(x),y_correct))
|
2 | Pass |
%%
x = realmax('single');
y_correct = '01111111011111111111111111111111';
assert(isequal(single2bin(x),y_correct))
|
3 | Pass |
%%
x = realmin('single');
y_correct = '00000000100000000000000000000000';
assert(isequal(single2bin(x),y_correct))
|
4 | Pass |
%%
x = single(-1.625e21);
y_correct = '11100010101100000010111011001111';
assert(isequal(single2bin(x),y_correct))
|
Find the sum of all the numbers of the input vector
31951 Solvers
434 Solvers
Find nearest prime number less than input number
268 Solvers
219 Solvers
250 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!