Cody

Solution 2200658

Submitted on 8 Apr 2020 by Lorenzo Monteil
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 = 3; b = 4; c = 5; flag_correct = true; assert(isequal(isRightAngled(a,b,c),flag_correct))

A = 9 16 25 B = 25 34 41 c = 1×3 logical array 0 0 1

2   Pass
a = 3; b = 4; c = 6; flag_correct = false; assert(isequal(isRightAngled(a,b,c),flag_correct))

A = 9 16 36 B = 25 45 52 c = 1×3 logical array 0 0 0

3   Pass
a = 3; b = 5; c = 4; flag_correct = true; assert(isequal(isRightAngled(a,b,c),flag_correct))

A = 9 25 16 B = 34 25 41 c = 1×3 logical array 0 1 0

4   Pass
a = 4; b = 3; c = 5; flag_correct = true; assert(isequal(isRightAngled(a,b,c),flag_correct))

A = 16 9 25 B = 25 41 34 c = 1×3 logical array 0 0 1

5   Pass
a = 4; b = 5; c = 3; flag_correct = true; assert(isequal(isRightAngled(a,b,c),flag_correct))

A = 16 25 9 B = 41 25 34 c = 1×3 logical array 0 1 0

6   Pass
a = 5; b = 3; c = 4; flag_correct = true; assert(isequal(isRightAngled(a,b,c),flag_correct))

A = 25 9 16 B = 34 41 25 c = 1×3 logical array 1 0 0

7   Pass
a = 5; b = 4; c = 3; flag_correct = true; assert(isequal(isRightAngled(a,b,c),flag_correct))

A = 25 16 9 B = 41 34 25 c = 1×3 logical array 1 0 0

8   Pass
a = 5; b = 12; c = 13; flag_correct = true; assert(isequal(isRightAngled(a,b,c),flag_correct))

A = 25 144 169 B = 169 194 313 c = 1×3 logical array 0 0 1