One Liner
Complexity

Time complexity:
O(1)


Space complexity:
O(1)

Code
# Complexity
- Time complexity:
$$O(1)$$

- Space complexity:
$$O(1)$$

# Code
```typescript []
const isRectangleOverlap = (rec1: [number, number, number, number], rec2: typeof rec1) =>
    rec1[0] < rec2[2] && rec1[1] < rec2[3] && rec1[2] > rec2[0] && rec1[3] > rec2[1];
```
```javascript []
const isRectangleOverlap = (rec1, rec2) =>
    rec1[0] < rec2[2] && rec1[1] < rec2[3] && rec1[2] > rec2[0] && rec1[3] > rec2[1];
```
['Array', 'Math', 'Brainteaser', 'Geometry', 'Matrix', 'TypeScript', 'JavaScript']