Problem 2861. Is the test point on the line segment?
Solution Stats
Problem Comments
-
2 Comments
Your recent edit to the test suite broke it. You need a space or a comma between the two -1 in the definition of pa in the first test.
Thanks, Guillaume. I just fixed the error.
Solution Comments
-
1 Comment
perhaps a few more test cases will help...
-
2 Comments
This is not a proper solution. For example it returns false negative for pa = [0,0,0]; pb = [3,3,0]; pc = [2,2,0]; and false positive for pa = [0,0,0]; pb = [3,3,3]; pc = [2,2,1];
Thanks for pointing this out, Jan.
Problem Recent Solvers17
Suggested Problems
-
Return the 3n+1 sequence for n
7030 Solvers
-
Generate a vector like 1,2,2,3,3,3,4,4,4,4
6715 Solvers
-
Square Digits Number Chain Terminal Value (Inspired by Project Euler Problem 92)
190 Solvers
-
Sum of odd numbers in a matrix
403 Solvers
-
241 Solvers
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!