[SW Expert Academy, SWEA 2068] 최대수 구하기 (python)
Problem Solving/SWEA

[SW Expert Academy, SWEA 2068] 최대수 구하기 (python)

728x90

https://swexpertacademy.com/main/code/problem/problemDetail.do?problemLevel=1&contestProbId=AV5QQhbqA4QDFAUq&categoryId=AV5QQhbqA4QDFAUq&categoryType=CODE&problemTitle=&orderBy=FIRST_REG_DATETIME&selectCodeLang=ALL&select-1=1&pageSize=10&pageIndex=1

 

SW Expert Academy

SW 프로그래밍 역량 강화에 도움이 되는 다양한 학습 컨텐츠를 확인하세요!

swexpertacademy.com


※ SW Expert 아카데미의 문제를 무단 복제하는 것을 금지합니다.

728x90

T = int(input())

for test_case in range(1, T + 1):
    lst = map(int, input().split())

    max_lst = 0

    for l in lst:
        if max_lst < l:
            max_lst = l

    print("#{} {}".format(test_case, max_lst))

max 함수 사용

T = int(input())

for test_case in range(1, T + 1):
    lst = map(int, input().split())

    max_lst = max(lst)

    print("#{} {}".format(test_case, max_lst))
728x90