Editorial for Квадраттар қосындысы


Remember to use this editorial only when stuck, and not to copy-paste code from it. Please be respectful to the problem author and editorialist.
Submitting an official solution before solving the problem yourself is a bannable offence.

Hint 1.

Бұл қосынды бірнеше мүшеден тұрады, әрқайсысы белгілі бір заңдылықпен анықталады.

Hint 2.

\(1\)-ден \(n\)-ге дейінгі әр сан үшін оның квадратын есептеп, осы мәндерді қарастыру керек.

Hint 3.

Барлық квадраттарды біртіндеп қосып, нәтижені есептеңіз.