Problem 45346. Grazing-02
Solution Stats
Problem Comments
-
6 Comments
Asif -- I am getting a different result for test problem 6.
I got the same answer as you. I think it is correct.
@william
in test 6,there will be an overlap. if u consider that, i think it should be ok.
i'll add some more test cases like that.
Ooops! I didn't consider that.
If the rope is so longer than the rectangle barn and the cow can turn round and round, 3 of "4 quadrants" does not increase the grazing area, it is just 3/4 sector of a circle. The problem is 1 of 4 quadrants.
I'm also not sure that the last test case is in fact correct. (And yes, I have considered the overlap.)
Solution Comments
Show commentsProblem Recent Solvers10
Suggested Problems
-
477 Solvers
-
Increment a number, given its digits
650 Solvers
-
Back to basics 12 - Input Arguments
596 Solvers
-
Given a matrix, swap the 2nd & 3rd columns
1072 Solvers
-
Create an array (n,n) where only diagonal elements are '1' and others are '0'
82 Solvers
More from this Author165
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!