Cody

# Problem 23. Finding Perfect Squares

Solution 2685629

Submitted on 13 Jul 2020 by Javier Maldonado Palma
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 = [2 3 4]; assert(isequal(isItSquared(a),true))

b = logical 0 l = 3 value = 4 b = logical 1 value = 9 value = 16

2   Pass
a = [20:30]; assert(isequal(isItSquared(a),false))

b = logical 0 l = 11 value = 400 value = 441 value = 484 value = 529 value = 576 value = 625 value = 676 value = 729 value = 784 value = 841 value = 900

3   Pass
a = [1]; assert(isequal(isItSquared(a),true))

b = logical 0 l = 1 value = 1 b = logical 1

4   Pass
a = [6 10 12 14 36 101]; assert(isequal(isItSquared(a),true))

b = logical 0 l = 6 value = 36 b = logical 1 value = 100 value = 144 value = 196 value = 1296 value = 10201

5   Pass
a = [6 10 12 14 101]; assert(isequal(isItSquared(a),false))

b = logical 0 l = 5 value = 36 value = 100 value = 144 value = 196 value = 10201

### Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!