Cody

# Problem 768. Are all the three given point in the same line?

Solution 1350531

Submitted on 20 Nov 2017 by Rafael Hernandez-Walls
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 = [-1 1 0]; Y=[-1 1 0]; y_correct = 1; assert(isequal(your_fcn_name(X,Y),y_correct))

f = -1 1 0 ans = logical 1

2   Pass
X = [0 3 6]; Y=[5 7 9]; y_correct = 1; assert(isequal(your_fcn_name(X,Y),y_correct))

f = 5 7 9 ans = logical 1

3   Pass
X = [0 7 14]; Y=[-7 -5 -3]; y_correct = 1; assert(isequal(your_fcn_name(X,Y),y_correct))

f = -7 -5 -3 ans = logical 1

4   Pass
X = [10 12 -10]; Y=[-7 -3 47]; y_correct = 0; assert(isequal(your_fcn_name(X,Y),y_correct))

f = -2.3000 -7.2000 46.6000 ans = logical 0

5   Pass
X = [0 0.8 1]; Y=[0.2 1 1]; y_correct = 0; assert(isequal(your_fcn_name(X,Y),y_correct))

f = 0.2000 0.9000 1.1000 ans = logical 0

### Community Treasure Hunt

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

Start Hunting!