프로젝트 오일러 도전기 #6 (with 파이썬 프로그래밍공부)
문제 Sum square difference The sum of the squares of the first ten natural numbers is, 1 2 + 2 2 + ... + 10 2 = 385 The square of the sum of the first ten natural numbers is, (1 + 2 + ... + 10) 2 = 55 2 = 3025 Hence the difference between the sum of the squares of the first ten natural numbers and the square of the sum is 3025 - 385 = 2640 Find the difference between the sum of the squares of the first one hundred natural numbers and the square of the sum. 1부터 100까지 "제곱의 합"과 "합의 제곱"의 차는? 1부터 10까지 자연수를 각각 제곱해 더하면 다음과 같습니다 (제곱의 합). 1 2 + 2 2 + ... + 10 2 = 385 1부터 10을 먼저 더한 다음에 그 결과를 제곱하면 다음과 같습니다 (합의 제곱). (1 + 2 + ... + 10) 2 = 55 2 = 3025 따라서 1부터 10까지 자연수에 대해 "합의 제곱"과 "제곱의 합" 의 차이는 3025 - 385 = 2640 이 됩니다. 그러면 1부터 100까지 자연수에 대해 "합의 제곱"과 "제곱의 합"의 차이는 얼마입니까?