Logo
(追記) (追記ここまで)

24848번 - Race 다국어

시간 제한메모리 제한제출정답맞힌 사람정답 비율
2 초 512 MB91150.000%

문제

The race for $n$ sportsmen is organized at a stadium. The sportsmen are running along $n$ linear tracks of the stadium. Let us consider each track to be a horizontal line, the $i$-th track is a line $y = i$.

The sportsman $i$ starts running at a point $(s_i, i)$ and runs to the right with the speed of $v_i$. The race is long, so let us consider that it never ends, and the sportsmen never stop.

Young photographer Daniel is watching the race. He wonders what is the maximum number of sportsmen that would at some moment be on the same straight line. Help him find that out!

입력

Tha first line of input contains an integer $n$ --- the number of race participants (1ドル \le n \le 300$).

The following $n$ lines describe sportsmen, the $i$-th of them contains two integers $s_i$ and $v_i$ --- the initial $x$-coordinate of the $i$-th sportsman and her speed ($-10^6 \le s_i \le 10^6$; 1ドル \le v_i \le 10^6$).

출력

Output one integer --- the maximum number of sportsmen that would be on the same straight line during the race.

제한

예제 입력 1

3
0 1
0 3
3 2

예제 출력 1

3

힌트

출처

Olympiad > Russian Olympiad in Informatics > Russia High School Programming Contest > Russia High School Programming Contest 2021 F번

(追記) (追記ここまで)

출처

대학교 대회

  • 사업자 등록 번호: 541-88-00682
  • 대표자명: 최백준
  • 주소: 서울시 서초구 서초대로74길 29 서초파라곤 412호
  • 전화번호: 02-521-0487 (이메일로 연락 주세요)
  • 이메일: contacts@startlink.io
  • 통신판매신고번호: 제 2017-서울서초-2193 호

AltStyle によって変換されたページ (->オリジナル) /