Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 6 additions & 8 deletions app.py
Original file line number Diff line number Diff line change
@@ -1,14 +1,12 @@
def add():
x = int(input("Enter your number 1: "))
y = int(input("Enter your number 2: "))
z = x+y
print("Your final result is: ", z)
print("Your final result is: ", x+y)

def multiply():
x = int(input("Enter your number 1: "))
y = int(input("Enter your number 2: "))
z = x*y
print("Your final result is: ", z)
print("Your final result is: ", x*y)

def factorial():
x = int(input("enter your number:"))
Expand All @@ -17,10 +15,10 @@ def factorial():
elif x == 0:
print("The factorial of 0 is 1.")
else:
factorial=1
fact=1
for i in range(1,x + 1):
factorial = factorial*i
print("The factorial of",x,"is",factorial)
fact *= i
print("The factorial of",x,"is",fact)

def fibonacci():
n = int(input("Enter the number: "))
Expand Down Expand Up @@ -69,7 +67,7 @@ def palindrome():
print("Not Palindrome")

def armstrong():
n = int(input("Enter a number"))
n = int(input("Enter a number: "))
order = len(str(n))
sum = 0
temp = n
Expand Down