You are given two integers xCorner and yCorner representing the coordinates of the top-right corner of an axis-aligned rectangle whose bottom-left corner is at (0, 0).
You are also given an array circles, where each element circles[i] = [xi, yi, ri] represents a circle centered at (xi, yi) with radius ri.
Your task is to determine whether it is possible to travel from (0, 0) to (xCorner, yCorner) entirely inside the rectangle, without touching or entering any circle.
The path must only touch the rectangle at the starting and ending points.
Return true if such a path exists; otherwise, return false.
Input: xCorner = 6, yCorner = 4, circles = [[1,3,1],[4,2,1]]
Output: true
Explanation:
Even though there are two circles, there is still free space to create a curved path around them.
Input: xCorner = 2, yCorner = 6, circles = [[1,3,2]]
Output: false
Explanation:
The circle reaches both left and right sides of the rectangle, blocking movement.
Input: xCorner = 5, yCorner = 5, circles = [[3,3,1]]
Output: true
Explanation:
The circle is far from the diagonal area, so a path exists avoiding the circle.
Input: xCorner = 4, yCorner = 4, circles = [[2,2,3]]
Output: false
Explanation:
The circle fully blocks all possible paths from one corner to the other.
Accepted:
Submission: