Oct-23-2018, 04:54 AM
You should use a version so this work.
Which mean 3.6 or preferably 3.7.
Install for Windows Python 3.6/3.7 and pip installation under Windows,
for Linux so comes newer distros like Ubuntu 18.10 and Mint 19 with Python 3.6.5 as default install.
Which mean 3.6 or preferably 3.7.
price_meal = float(input("How much did your meal cost? ")) tip = float(input("How much do you want to tip, in decimal form? ")) price_meal += price_meal + tip print(f'Your total cost is {price_meal:.2f}.')
f-string
is the newest way.Install for Windows Python 3.6/3.7 and pip installation under Windows,
for Linux so comes newer distros like Ubuntu 18.10 and Mint 19 with Python 3.6.5 as default install.