Could You Please find why ,it's giving wrong result ⬇️
n=4
i=1
while(i<n):
f=n*i
if i==n-1:
break
else:
i=i+1
print("factorial=",f)
I want output : 24
gokulgopi645:
Please ans
Answers
Answered by
0
Answer:
Ok then write the question properly
Answered by
0
Answer:
n=4
i=1
f=0
while (i<n):
j = i*n
f = j+f
i = i+1
print ("Factorial of the Number is:",f)
Explanation:
Your looping was not right.
Similar questions