Difference of Squares Exercise is completed
def square_of_sum(number):
square = 0
for i in range(number+1):
square += i
return square ** 2
def sum_of_squares(number):
sum = 0
for i in range(number+1):
sum += i*i
return sum
def difference_of_squares(number):
return square_of_sum(number) - sum_of_squares(number)
Thank you, friend!
I'm @steem.history, who is steem witness.
Thank you for witnessvoting for me.
please click it!
(Go to https://steemit.com/~witnesses and type fbslo at the bottom of the page)
The weight is reduced because of the lack of Voting Power. If you vote for me as a witness, you can get my little vote.