Cody

# Problem 1103. Right Triangle Side Lengths (Inspired by Project Euler Problem 39)

Solution 2867822

Submitted on 22 Aug 2020 by Anush Reddy pittu
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
assert(isequal(right_triangle_sides(240),{ [15 112 113] [40 96 104] [48 90 102] [60 80 100] }))

d = 0×0 empty cell array

2   Pass
assert(isequal(right_triangle_sides(240),{ [15 112 113] [40 96 104] [48 90 102] [60 80 100] }))

d = 0×0 empty cell array

3   Pass
assert(isequal(right_triangle_sides(418),{ [57 176 185] }))

d = 0×0 empty cell array

4   Pass
assert(isequal(right_triangle_sides(490),{ [140 147 203] }))

d = 0×0 empty cell array

5   Pass
assert(isequal(right_triangle_sides(112),{ [14 48 50] }))

d = 0×0 empty cell array

6   Pass
assert(isequal(right_triangle_sides(390),{ [52 165 173] [65 156 169] }))

d = 0×0 empty cell array

7   Pass
assert(isequal(right_triangle_sides(132),{ [11 60 61] [33 44 55] }))

d = 0×0 empty cell array

8   Pass
assert(isequal(right_triangle_sides(576),{ [64 252 260] [144 192 240] }))

d = 0×0 empty cell array

9   Pass
assert(isequal(right_triangle_sides(60),{ [10 24 26] [15 20 25] }))

d = 0×0 empty cell array

10   Pass
assert(isequal(right_triangle_sides(650),{ [25 312 313] }))

d = 0×0 empty cell array

11   Pass
assert(isequal(right_triangle_sides(732),{ [183 244 305] }))

d = 0×0 empty cell array

12   Pass
assert(isequal(right_triangle_sides(648),{ [162 216 270] }))

d = 0×0 empty cell array

13   Pass
assert(isequal(right_triangle_sides(930),{ [155 372 403] }))

d = 0×0 empty cell array

14   Pass
assert(isequal(right_triangle_sides(876),{ [219 292 365] }))

d = 0×0 empty cell array

15   Pass
assert(isequal(right_triangle_sides(588),{ [84 245 259] [147 196 245] }))

d = 0×0 empty cell array

16   Pass
assert(isequal(right_triangle_sides(208),{ [39 80 89] }))

d = 0×0 empty cell array

17   Pass
assert(isequal(right_triangle_sides(228),{ [57 76 95] }))

d = 0×0 empty cell array

18   Pass
assert(isequal(right_triangle_sides(312),{ [24 143 145] [78 104 130] }))

d = 0×0 empty cell array

19   Pass
assert(isequal(right_triangle_sides(924),{ [42 440 442] [77 420 427] [132 385 407] [198 336 390] [231 308 385] }))

d = 0×0 empty cell array

20   Pass
assert(isequal(right_triangle_sides(980),{ [280 294 406] }))

d = 0×0 empty cell array

21   Pass
assert(isequal(right_triangle_sides(112),{ [14 48 50] }))

d = 0×0 empty cell array

22   Pass
assert(isequal(right_triangle_sides(30),{ [5 12 13] }))

d = 0×0 empty cell array

23   Pass
assert(isequal(right_triangle_sides(680),{ [102 280 298] [136 255 289] }))

d = 0×0 empty cell array

24   Pass
assert(isequal(right_triangle_sides(396),{ [33 180 183] [72 154 170] [99 132 165] }))

d = 0×0 empty cell array

25   Pass
assert(isequal(right_triangle_sides(988),{ [266 312 410] }))

d = 0×0 empty cell array

### Community Treasure Hunt

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

Start Hunting!