rolf
This commit is contained in:
20
cgi-bin/vorbereitung/rolfhaist.py
Normal file
20
cgi-bin/vorbereitung/rolfhaist.py
Normal file
@@ -0,0 +1,20 @@
|
||||
#!/usr/bin/python3
|
||||
|
||||
import cgi
|
||||
|
||||
print("Content-type:text/html")
|
||||
|
||||
def fac_iter(n):
|
||||
res = 1
|
||||
for i in range(1,n + 1):
|
||||
res *= i
|
||||
return res
|
||||
|
||||
def fak(n):
|
||||
if n <= 1:
|
||||
return 1
|
||||
else:
|
||||
return n * fak(n - 1)
|
||||
|
||||
print("LUL {} FORMAT".format(fac_iter(1000)))
|
||||
print("LUL {} FORMAT".format(fak(500)))
|
Reference in New Issue
Block a user