There was an error while loading. Please reload this page.
1 parent 0517667 commit 3d627c5Copy full SHA for 3d627c5
Status/Day 1.md
@@ -82,7 +82,7 @@ print fact(x)
82
# Solution by: harshraj22
83
84
n = int(input())
85
- def shortFact(x): return x if x is 1 else x*shortFact(x-1)
+ def shortFact(x): return 1 if x <= 1 else x*shortFact(x-1)
86
print(shortFact(n))
87
88
```
0 commit comments