Skip to content

Fixed coding style problem 33 fixes: #2786 #2849

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 2 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions project_euler/problem_33/sol1.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,17 +23,17 @@ def isDigitCancelling(num, den):
return True


def solve(digit_len: int) -> str:
def solution(digit_len: int) -> str:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add the default value for the parameter digit_len such that when called without any arguments solution() returns the right answer to the solution.

"""
>>> solve(2)
>>> solution(2)
'16/64 , 19/95 , 26/65 , 49/98'
>>> solve(3)
>>> solution(3)
'16/64 , 19/95 , 26/65 , 49/98'
>>> solve(4)
>>> solution(4)
'16/64 , 19/95 , 26/65 , 49/98'
>>> solve(0)
>>> solution(0)
''
>>> solve(5)
>>> solution(5)
'16/64 , 19/95 , 26/65 , 49/98'
"""
solutions = []
Expand All @@ -52,4 +52,4 @@ def solve(digit_len: int) -> str:


if __name__ == "__main__":
print(solve(2))
print(solution(2))