RiseOJ는 solved.ac와 제휴 관계가 없습니다. 티어 아이콘 © solved.ac. solved.ac
포럼
문제 ICPC00115

E. Cakes

설명

1

This summer, you plan to organize a large party and invite many friends. They have a sweet tooth, so you plan to bake nice cakes for them. You know the recipe for a nice chocolate cake, and you want to cook as many of them as possible.

Given the \(N\) ingredients needed to make a single cake and the ingredients that you have in your kitchen, how many cakes can you make?

제약
입력 형식
  • The first line of the input contains a single integer \(N\).
  • Then, \(N\) lines follow, one for each ingredient. Each of these lines contains two positive integers: the first one is the required quantity of this ingredient per cake, the second one is the quantity of this ingredient you have in your kitchen.
출력 형식

The output should contain a single integer: the maximum number of cakes you can make using the available ingredients.

예제 1
입력
3
100 500
2 5
70 1000
출력
2
예제 2
입력
3
100 50
2 5
70 1000
출력
0
문제 정보

생성자가 기록되지 않았습니다.

출처 ICPC SWERC 2020

평가 및 의견

E. Cakes

개요
출제자 난이도 Unrated 레이팅 미적용 의견 0 / 50 공개 집계 (커뮤니티 난이도, 주요 주제, 품질)는 의견이 충분히 모이면 공개됩니다.

Log in to rate problems.

개별 의견

아직 의견이 없습니다. 자격이 된다면 위 양식에서 가장 먼저 평가해 보세요.

풀이 제출

E. Cakes

게스트로 둘러보고 있습니다. 로그인하면 풀이를 제출하고 진행 상황을 확인할 수 있습니다. 로그인하고 제출하기
공개
C++20 Tab 들여쓰기 · Ctrl+/ 주석 토글 · Enter 자동 들여쓰기
1 1 1 0 공백: 4 · UTF-8