백준2410 [백준/파이썬] 20571번 Elevators -Codedef solution(section, num): if section == "residential": if num == 1: return 1 elif 2 2025. 4. 11. [백준/파이썬] 33779번 Back and Forth -Codes = input()print("beep" if s == s[::-1] else "boop") 2025. 4. 10. [백준/파이썬] 24867번 Два станка -Codek = int(input())a, x = map(int, input().split())b, y = map(int, input().split())case1 = (k - a) * xcase2 = (k - b) * ycase3 = (k - a) * x + (k - a - b) * ycase4 = (k - b) * y + (k - a - b) * xprint(max(case1, case2, case3, case4, 0)) 2025. 4. 9. [백준/파이썬] 22123번 Экзамен -Codefor _ in range(int(input())): s, f, m = input().split() s_h, s_m, s_s = map(int, s.split(":")) f_h, f_m, f_s = map(int, f.split(":")) m = int(m) * 60 s_total = s_h * 3600 + s_m * 60 + s_s f_total = f_h * 3600 + f_m * 60 + f_s test_time = f_total - s_total if test_time = m: print("Perfect") elif test_time + 3600 >= m: print("Test") else: pri.. 2025. 4. 8. [백준/파이썬] 9806번 The King -Coden = int(input())k = int(input())li = list(map(int, input().split()))li_res = [el ** k for el in li]total = 0for el in li_res: if el > 0: total += elprint(total) 2025. 4. 7. [백준/파이썬] 32449번 Animal Farm -Coden = int(input())others = []max_pig = 0for _ in range(n): s, i = input().split() i = int(i) if s == "pig": max_pig = max(max_pig, i) else: others.append(i)res = max_pigfor i in others: if i 2025. 4. 6. 이전 1 2 3 4 ··· 402 다음