MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn moreOpportunities for recent engineering grads.

Apply TodayIf a number (n) is provided as an input, find the square of the sum of the digits of the number.

Example

If n = 21, the answer will be square of (2 + 1) = 9

35 correct solutions
37 incorrect solutions

Last solution submitted on Dec 06, 2014

1 Comment

Joseph Pauwels
on 13 May 2014

-4 + 3 +1=0 right. I don't remember you saying the absolute value in the instructions.

1 Comment