목록분류 전체보기 (317)
지나가던 개발자

for i in range(int(input())): print("Case #%d:"%(i+1), " ".join(list(reversed(input().split(" ")))))

from string import ascii_uppercase for i in range(int(input())): tc = [x for x in list(input().upper().replace(" ", "")) if x in list(ascii_uppercase)] if set(tc) == set(ascii_uppercase): triple_pangram = True double_pangram = True pangram = True for j in set(tc): if tc.count(j) >= 3: continue elif tc.count(j) == 2: triple_pangram = False elif tc.count(j) == 1: double_pangram = False if triple_p..

names = [] for i in range(int(input())): names.append(input()) if sorted(names) == names: print("INCREASING") elif sorted(names, reverse=True) == names: print("DECREASING") else: print("NEITHER")

rate = 0 scoreSum = 0 rating = {"A+": 4.5, "A0": 4.0, "B+": 3.5, "B0": 3.0, "C+": 2.5, "C0": 2.0, "D+": 1.5, "D0": 1.0, "F": 0.0} for i in range(20): subject, score, grade = input().split() if grade == "P": continue rate += float(score) * rating[grade] scoreSum += float(score) print(rate/scoreSum)

from string import ascii_uppercase, ascii_lowercase longest = "" while True: s = input().split() if s == []: continue for i in range(len(s)): s[i] = list(s[i]) for j in range(len(s[i])): if s[i][j] in list(ascii_uppercase) or s[i][j] in list(ascii_lowercase) or s[i][j] == "-": continue s[i][j] = "" s[i] = "".join(s[i]) s.sort(key=len, reverse=True) if "E-N-D" in s: if s[0] == "E-N-D": if len(lon..

from string import ascii_uppercase, ascii_lowercase encryption = {" ": 0} for i in range(1, len(list(ascii_uppercase)+list(ascii_lowercase))+1): encryption[(list(ascii_uppercase)+list(ascii_lowercase))[i-1]] = i n = int(input()) numbers = list(map(int, input().split())) plaintext = [] for i in input(): plaintext.append(encryption[i]) if sorted(numbers) == sorted(plaintext): print("y") else: prin..

import math n, m = map(int, input().split(":")) print(str(n//math.gcd(n, m))+":"+str(m//math.gcd(n, m)))

for i in range(int(input())): s = input() l = [] for j in range(0, len(s), int(len(s)**(0.5))): l.append(s[j:j+int(len(s)**0.5)]) for j in range(int(len(s)**(0.5))-1, -1, -1): for k in range(int(len(s)**(0.5))): print(l[k][j], end="") print("") 웃긴게 맨 마지막 줄에 를 입력 안 하면 틀렸습니다가 뜬다..