Problem 1074. Property dispute!
Solution Stats
Problem Comments
-
1 Comment
I fixed the test suite, which had a problem described by Alfonso below.
Solution Comments
-
5 Comments
I believe in test set 3 c should be empty?
In test 3, A is wholly contained within B. But I added another test case that should return the empty set [].
Perhaps you are referring to test 5, in test 3 a box with width/height [6,1] is hardly contained in a box with width/height [2,2]... or perhaps i am misinterpreting?
Most previous solutions returned [0 0 0 0] for no intersection since that is what the test suite seemed to want.
My apologies. I don't know why I had this wrong before, but according to my description, yes, test 3 should return [].
-
1 Comment
why are results of test 3 and 7 not consistent ? is it possible to fix it ? by the way, [0 0 0 0] was easier to get...
-
2 Comments
This only works for integer coordinates.
I added a test with non-integer inputs.
Problem Recent Solvers31
Suggested Problems
-
Project Euler: Problem 4, Palindromic numbers
760 Solvers
-
653 Solvers
-
Find third Side of a right triangle given hypotenuse and a side. No * - or other functions allowed
169 Solvers
-
Determine the number of odd integers in a vector
601 Solvers
-
Remove entire row and column in the matrix containing the input values
270 Solvers
More from this Author50
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!