1515. 服务中心的最佳位置

Hard | Array, Math, Geometry, Randomized

2026年4月23日 · 3 分钟

497. 非重叠矩形中的随机点

Medium | Array, Math, Binary Search, Reservoir Sampling, Prefix Sum, Ordered Set, Randomized

2026年4月21日 · 3 分钟

519. 随机翻转矩阵

Medium | Hash Table, Math, Reservoir Sampling, Randomized

2026年4月21日 · 3 分钟

528. 按权重随机选择

Medium | Array, Math, Binary Search, Prefix Sum, Randomized

2026年4月21日 · 3 分钟

710. 黑名单中的随机数

Hard | Array, Hash Table, Math, Binary Search, Sorting, Randomized

2026年4月21日 · 3 分钟

380. 常数时间插入、删除和获取随机元素

Medium | Array, Hash Table, Math, Design, Randomized

2026年4月20日 · 3 分钟

381. O(1) 时间插入、删除和获取随机元素 - 允许重复

Hard | Array, Hash Table, Math, Design, Randomized

2026年4月20日 · 3 分钟

382. 链表随机节点

Medium | Linked List, Math, Reservoir Sampling, Randomized

2026年4月20日 · 2 分钟

384. 打乱数组

Medium | Array, Math, Design, Randomized

2026年4月20日 · 2 分钟

398. 随机数索引

Medium | Hash Table, Math, Reservoir Sampling, Randomized

2026年4月20日 · 2 分钟