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.
perhaps a few more test cases will help...
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.
Knight's Tour Checker
poll: would you like the regexp (?@cmd) functionality to be banned in Cody?
Count number of words in string
Test Problem; Create a 5x5 array containing all ones
Find the treasures in MATLAB Central and discover how the community can help you!
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Contact your local office