본문 바로가기
Beakjoon&프로그래머스/파이썬

[백준/파이썬] 28701번 세제곱의 합

by 현장 2023. 8. 15.

-Code

n = int(input())
res = n * (n + 1) // 2
print(res)
print(res ** 2)
print(res ** 2)