logo

Crowdly

Write a function named “sumSquares”, that takes a positive integer n and calc...

✅ Перевірена відповідь на це питання доступна нижче. Наші рішення, перевірені спільнотою, допомагають краще зрозуміти матеріал.

Write a function named “sumSquares”, that takes a positive

integer

n

and calculates the sum of the squares of all integers from 1

to

n.

That is, the function should calculate:

For example, if a user inputs =sumSquares(3) into a cell,

the result should be 14 (

).

[Expected time to answer: 12 mins]

Більше питань подібних до цього

Хочете миттєвий доступ до всіх перевірених відповідей на moodle.lisboa.ucp.pt?

Отримайте необмежений доступ до відповідей на екзаменаційні питання - встановіть розширення Crowdly зараз!