I want to define a function factorial(x), but the way I want to do it
x = int(input("x"))
needs to be inside the function
The function should be recursive. So it needs to call on itself.
I tried to do it but since taking input is called every recursive step, the function doesn't work in expected way.
Can anyone define such a working function?