psf/black code formatting (#1277)

This commit is contained in:
William Zhang
2019-10-05 01:14:13 -04:00
committed by Christian Clauss
parent 07f04a2e55
commit 9eac17a408
291 changed files with 6014 additions and 4571 deletions

View File

@ -6,6 +6,8 @@ the product of two 2-digit numbers is 9009 = 91 x 99.
Find the largest palindrome made from the product of two 3-digit numbers which
is less than N.
"""
def solution(n):
"""Returns the largest palindrome made from the product of two 3-digit
numbers which is less than n.
@ -31,9 +33,7 @@ def solution(n):
# if 'number' is a product of two 3-digit numbers
# then number is the answer otherwise fetch next number.
while divisor != 99:
if (number % divisor == 0) and (
len(str(int(number / divisor))) == 3
):
if (number % divisor == 0) and (len(str(int(number / divisor))) == 3):
return number
divisor -= 1