Cody

# Problem 44085. Can the given sides form a triangle?

Solution 1138791

Submitted on 14 Mar 2017 by yurenchu
• Size: 16
• This is the leading solution.
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
x = [3 4 5]; y_correct = true; assert(isequal(isTriangle(x),y_correct))

ans = logical 1

2   Pass
x = [1 3 5]; y_correct = false; assert(isequal(isTriangle(x),y_correct))

ans = logical 0

3   Pass
x = [6 5 3]; y_correct = true; assert(isequal(isTriangle(x),y_correct))

ans = logical 1

4   Pass
x = [3 3 3]; y_correct = true; assert(isequal(isTriangle(x),y_correct))

ans = logical 1

5   Pass
x = [4 7 5]; y_correct = true; assert(isequal(isTriangle(x),y_correct))

ans = logical 1

6   Pass
x = [5 8 3]; y_correct = false; assert(isequal(isTriangle(x),y_correct))

ans = logical 0

### Community Treasure Hunt

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

Start Hunting!