백준/C
[BaeKJoon/C] 백준20254 c site score
coose
2021. 5. 22. 18:31
반응형
https://www.acmicpc.net/problem/20254
20254번: Site Score
Teams from variaous universities compete in ICPC regional contests for tickets to the ICPC World Finals. The number of tickets allocated to every regional contest may be different. The allocation method in our super region, Asia Pacific, is based on a para
www.acmicpc.net
문제
2020년 타이페이-신추 지역 대회의 현장 점수는 56UR + 24TR + 14UO + 6TO이다. 2020년 타이페이-신추 지역 콘테스트의 현장 점수를 계산하는 프로그램을 작성해 주세요.
풀이
TH = (UR * 56) + (TR * 24) + (UO * 14) + (TO * 6);
코드
#include <stdio.h>
int main() {
int UR, TR, UO, TO, TH;
scanf("%d %d %d %d", &UR, &TR, &UO, &TO);
TH = (UR * 56) + (TR * 24) + (UO * 14) + (TO * d);
printf("%d", TH);
}
|
cs |
반응형