본문 바로가기
백준문제/브론즈 5

백준) 28701번 - python

by kiseno 2024. 3. 2.
728x90
반응형
SMALL
n = int(input())
result, lst, final = 0,[],0
for i in range(1,n+1):
    lst.append(i)
    result += i
print(result)
print(result ** 2)
for i in range(len(lst)): final += lst[i] ** 3
print(final)
728x90
반응형
LIST

'백준문제 > 브론즈 5' 카테고리의 다른 글

백준) 29163번 - python  (0) 2024.03.04
백준) 28927번 - python  (0) 2024.03.03
백준) 25314번 - python  (1) 2024.03.01
백준) 14645번 - python  (0) 2024.02.29
백준) 11021번 - python  (0) 2024.02.28