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

J2. Fergusonball Ratings

Unrated 레이팅 미적용
난이도
2s
시간 제한
256MB
메모리 제한
0
맞았습니다!!
0
제출 수
0.0%
정답률
레이팅

의견: 0

설명

Fergusonball players are given a star rating based on the number of
points that they score and the number of fouls that they commit.
Specifically, they are awarded \(5\)
stars for each point scored, and \(3\)
stars are taken away for each foul committed. For every player, the
number of points that they score is greater than the number of fouls
that they commit.

Your job is to determine how many players on a team have a star
rating greater than \(40\). You also
need to determine if the team is considered a gold team which means that
all the players have a star rating greater than
\(40\).

제약
입력 형식

The first line of input consists of a positive integer \(N\) representing the total number of
players on the team. This is followed by a pair of consecutive lines for
each player. The first line in a pair is the number of points that the
player scored. The second line in a pair is the number of fouls that the
player committed. Both the number of points and the number of fouls, are
non-negative integers.

출력 형식

Output the number of players that have a star rating greater than
\(40\), immediately followed by a plus
sign if the team is considered a gold team.

예제 1
입력
3
12
4
10
3
9
1
출력
3+
설명

The image shows the star rating for each player. For example, the
star rating for the first player is \(12 \times 5 - 4 \times 3 = 48\).

All three players have a rating
greater than \(40\) so the team is
considered a gold team.

예제 2
입력
2
8
0
12
1
출력
1
설명

The image shows the star rating for each player.

Since only one of
the two players has a rating greater than \(40\), this team is not considered a gold
team.

문제 정보

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

출처 CCC 2022 Junior

평가 및 의견

J2. Fergusonball Ratings

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

Log in to rate problems.

개별 의견

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

풀이 제출

J2. Fergusonball Ratings

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