Linting
This commit is contained in:
parent
854a99118f
commit
d42df4943d
@ -22,11 +22,13 @@ function Problem6()
|
|||||||
|
|
||||||
Find the difference between the sum of the squares of the first one
|
Find the difference between the sum of the squares of the first one
|
||||||
hundred natural numbers and the square of the sum. Statement =#
|
hundred natural numbers and the square of the sum. Statement =#
|
||||||
|
|
||||||
n = 100
|
n = 100
|
||||||
square_of_sum = sum(i for i in (1:n))^2
|
square_of_sum = sum(i for i = 1:n)^2
|
||||||
sum_squares = sum(i^2 for i in 1:n)
|
sum_squares = sum(i^2 for i = 1:n)
|
||||||
diff = square_of_sum - sum_squares
|
ans = square_of_sum - sum_squares
|
||||||
return diff
|
|
||||||
|
return ans
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user