type
status
date
slug
summary
tags
category
icon
password
创建时间
Dec 23, 2024 01:34 PM
给你一个以
(radius, xCenter, yCenter)
表示的圆和一个与坐标轴平行的矩形 (x1, y1, x2, y2)
,其中 (x1, y1)
是矩形左下角的坐标,而 (x2, y2)
是右上角的坐标。如果圆和矩形有重叠的部分,请你返回
true
,否则返回 false
。换句话说,请你检测是否 存在 点
(xi, yi)
,它既在圆上也在矩形上(两者都包括点落在边界上的情况)。通过坐标来判断
求圆心到矩形区域最短的距离
参考 圆和矩形是否有重叠