Public submissions
|Source code of every submission to this problem in this contest|will be visible for everyone since {$pdata.sc_from}.|
Problem hidden
|This problem was hidden by Editorial Board member probably because it has incorrect language|version or invalid test data, or description of the problem is not clear.|

PP115A2 - Suma kwadratów

Oblicz sumę kwadratów liczb: a, a+1, ..., b-1, b.

Wejście

Dwie liczby: 1 <= a <= b <=100.

Wyjście

Obliczona suma: a*a + (a+1)*(a+1) + ... + (b-1)*(b-1) + b*b

Przykład

Input:
1 4

Output:
30

Przykład 2

Input:
5 6

Output:
61

Dodane przez:kuszi
Data dodania:2011-11-24
Limit czasu wykonania programu:1s
Limit długości kodu źródłowego50000B
Limit pamięci:1536MB
Cluster: Cube (Intel G860)
Języki programowania:All except: ASM64 SCALA SCM qobi
Public source code since: 2012-06-16 15:43:52

© Spoj.com. All Rights Reserved. Spoj uses Sphere Engine™ © by Sphere Research Labs.