Skip to content

Commit a244df1

Browse files
authored
Update dynamic_programming/factorial.py
1 parent b7ecbf6 commit a244df1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: dynamic_programming/factorial.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ def factorial(num: int) -> int:
2222

2323
def factorial_aux(num, result):
2424

25-
if num == 0 or num == 1:
25+
if num in (0, 1):
2626
return 1
2727

2828
if result[num] != -1:

0 commit comments

Comments
 (0)