forked from exercism/problem-specifications
-
Notifications
You must be signed in to change notification settings - Fork 0
/
difference-of-squares.json
67 lines (67 loc) · 1.84 KB
/
difference-of-squares.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
{
"square_of_sum": {
"description": ["Square the sum of the numbers up to the given number"],
"cases": [
{
"description": "square of sum 5",
"number": 5,
"expected": 225
},
{
"description": "square of sum 10",
"number": 10,
"expected": 3025
},
{
"description": "square of sum 100",
"number": 100,
"expected": 25502500
}
]
},
"sum_of_squares": {
"description": ["Sum the squares of the numbers up to the given number"],
"cases": [
{
"description": "sum of squares 5",
"number": 5,
"expected": 55
},
{
"description": "sum of squares 10",
"number": 10,
"expected": 385
},
{
"description": "sum of squares 100",
"number": 100,
"expected": 338350
}
]
},
"difference_of_squares": {
"description": ["Subtract sum of squares from square of sums"],
"cases": [
{
"description": "difference of squares 0",
"number": 0,
"expected": 0
},
{
"description": "difference of squares 5",
"number": 5,
"expected": 170
},
{
"description": "difference of squares 10",
"number": 10,
"expected": 2640
},
{
"description": "difference of squares 100",
"number": 100,
"expected": 25164150
}
]
}
}