백준 13458번 시험감독
[BaekJoon] 백준 13458번 시험 감독
[BaekJoon] 백준 13458번 시험 감독 문제: www.acmicpc.net/problem/13458 내코드 - 그냥.. 계산문제 - 시험장에 응시자가 없는 경우를 간과해서 처음에 틀렸었다. import math N = int(input()) member = list(map(int, input().split())) B, C = map(int, input().split()) def main(): global N, member, B, C result = 0 for i in range(N): if member[i] > 0: member[i] -= B result += 1 if member[i] > 0: result += math.ceil(member[i] / C) print(result) main() 참고