Geometry LeetCode Problems: All 33, With Python Solutions
Every problem in this library that LeetCode tags Geometry — 33 in total, 28 of them with a complete Python solution, a worked example and the time and space complexity of the approach.
- 33 problems
- 9 Easy
- 14 Medium
- 10 Hard
How Geometry problems are solved
A tag names the subject, not the method. These pattern hubs cover the techniques that actually solve Geometry problems — each one explains the approach, gives a Python template and states its complexity.
- Math and Number Theory — Find the closed form, the invariant, or the modular identity — and skip the loop entirely.
Geometry problems by difficulty
Problems with a complete Python solution are listed first, then by ascending problem number.
Easy (9)
| # | Problem | Difficulty | Topics |
|---|---|---|---|
| 812 | Largest Triangle Area | Easy | Geometry, Array, Math |
| 836 | Rectangle Overlap | Easy | Geometry, Math |
| 883 | Projection Area of 3D Shapes | Easy | Geometry, Array, Math +1 |
| 892 | Surface Area of 3D Shapes | Easy | Geometry, Array, Math +1 |
| 1030 | Matrix Cells in Distance Order | Easy | Geometry, Array, Math +2 |
| 1037 | Valid Boomerang | Easy | Geometry, Array, Math |
| 1232 | Check If It Is a Straight Line | Easy | Geometry, Array, Math |
| 1266 | Minimum Time Visiting All Points | Easy | Geometry, Array, Math |
| 2481 | Minimum Cuts to Divide a Circle | Easy | Geometry, Math |
Medium (14)
| # | Problem | Difficulty | Topics |
|---|---|---|---|
| 223 | Rectangle Area | Medium | Geometry, Math |
| 478 | Generate Random Point in a Circle | Medium | Geometry, Math, Rejection Sampling +1 |
| 593 | Valid Square | Medium | Geometry, Math |
| 858 | Mirror Reflection | Medium | Geometry, Math, Number Theory |
| 939 | Minimum Area Rectangle | Medium | Geometry, Array, Hash Table +2 |
| 963 | Minimum Area Rectangle II | Medium | Geometry, Array, Hash Table +1 |
| 973 | K Closest Points to Origin | Medium | Geometry, Array, Math +4 |
| 1401 | Circle and Rectangle Overlapping | Medium | Geometry, Math |
| 1828 | Queries on Number of Points Inside a Circle | Medium | Geometry, Array, Math |
| 2101 | Detonate the Maximum Bombs | Medium | Depth-First Search, Breadth-First Search, Graph +3 |
| 2249 | Count Lattice Points Inside a Circle | Medium | Geometry, Array, Hash Table +2 |
| 2280 | Minimum Lines to Represent a Line Chart | Medium | Geometry, Array, Math +2 |
| 469 | Convex PolygonPremium | Medium | Geometry, Array, Math |
| 2152 | Minimum Number of Lines to Cover PointsPremium | Medium | Bit Manipulation, Geometry, Array +5 |
Hard (10)
| # | Problem | Difficulty | Topics |
|---|---|---|---|
| 149 | Max Points on a Line | Hard | Geometry, Array, Hash Table +1 |
| 335 | Self Crossing | Hard | Geometry, Array, Math |
| 391 | Perfect Rectangle | Hard | Geometry, Array, Hash Table +2 |
| 587 | Erect the Fence | Hard | Geometry, Array, Math |
| 1453 | Maximum Number of Darts Inside of a Circular Dartboard | Hard | Geometry, Array, Math |
| 1515 | Best Position for a Service Centre | Hard | Geometry, Array, Math +1 |
| 1610 | Maximum Number of Visible Points | Hard | Geometry, Array, Math +2 |
| 1924 | Erect the Fence IIPremium | Hard | Geometry, Array, Math |
| 1956 | Minimum Time For K Virus Variants to SpreadPremium | Hard | Geometry, Array, Math +2 |
| 2613 | Beautiful PairsPremium | Hard | Geometry, Array, Math +3 |
Keep exploring
- Array1,569
- String672
- Hash Table588
- Math485
- Dynamic Programming481
- Sorting392
- Greedy346
- Depth-First Search289
- Binary Search253
- Database249
- Tree225
- Breadth-First Search223
- Matrix216
- Two Pointers201
- Bit Manipulation194
- Binary Tree174
- Heap (Priority Queue)163
- Prefix Sum157
- Stack157
- Simulation144
- Graph138
- Counting126
- Design122
- Sliding Window116
When the Geometry problem arrives live
Stealth Interview is a desktop app for macOS and Windows. It reads the coding problem off your screen, returns a working solution with a step-by-step explanation and its time and space complexity, and transcribes what the interviewer is saying — while staying invisible to screen sharing.