Skip to content

Commit 73cfd73

Browse files
Add files via upload
1 parent 1b7fe0b commit 73cfd73

File tree

2 files changed

+14
-0
lines changed

2 files changed

+14
-0
lines changed

Diff for: Fun with Numbers/Adding currency.py

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
#Taking input and converting into float
2+
x = float(input("Enter a number: "))
3+
y = float(input("Enter another number: "))
4+
5+
#Estimating and printing the result
6+
z = (x + y)
7+
print(f"{z:,}")

Diff for: Fun with Numbers/Estimated result.py

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
#Taking input and converting into float
2+
x = float(input("Enter a number: "))
3+
y = float(input("Enter another number: "))
4+
5+
#Estimating and printing the result
6+
z = round(x + y)
7+
print(z)

0 commit comments

Comments
 (0)