AT_abc439_e [ABC439E] Kite

Description

> Happy New Year! When it comes to outdoor play on New Year's, it's kite flying! $ N $ people numbered $ 1 $ to $ N $ are trying to fly kites by the riverbank. The river facing the riverbank flows in a straight line, so from now on, we consider a two-dimensional coordinate system where the $ x $ -axis is the direction of the river and the $ y $ -axis is the height direction. Person $ i $ is standing at point $ (A_i, 0) $ and trying to fly a kite at point $ (B_i, 1) $ . However, to avoid collisions of people and kites, and to avoid kite strings getting tangled, persons $ i $ and $ j $ ( $ i \neq j $ ) cannot fly kites at the same time if the following condition is satisfied: - The "line segment connecting $ (A_i, 0) $ and $ (B_i, 1) $ " and the "line segment connecting $ (A_j, 0) $ and $ (B_j, 1) $ " have an intersection point. (This includes the case where the endpoints of the line segments touch each other.) What is the maximum number of people who can fly kites at the same time while respecting the above constraint?

Input Format

The input is given from Standard Input in the following format: > $ N $ $ A_1 $ $ B_1 $ $ A_2 $ $ B_2 $ $ \vdots $ $ A_N $ $ B_N $

Output Format

Output the maximum number of people who can fly kites at the same time.

Explanation/Hint

### Sample Explanation 1 Persons $ 1 $ and $ 2 $ , as well as persons $ 2 $ and $ 3 $ , can fly kites at the same time, but persons $ 1 $ and $ 3 $ cannot fly kites at the same time. Therefore, two people, if chosen appropriately, can fly kites at the same time, while it is impossible for three people to fly kites at the same time. Thus, the answer is $ 2 $ . ### Constraints - $ 1 \leq N \leq 2\times 10^5 $ - $ 0 \leq A_i \leq 10^9 $ - $ 0 \leq B_i \leq 10^9 $ - All input values are integers.