I am unable to get the tax amount using 6.75%100. Please help


#1

tax_float=6.75%100
OR
tax=6.75%100


#2

In python % is called a modulus. It will not do what you are trying to accomplish.

As a note you can convert any percent into decimal by moving the decimal to the right two places

EXAMPLE:

5% == 0.05
75% == 0.75

Easy, now when you write your code just write your percent as that and multiply or divide as needed.

To get a good tip let's write a function using this knowledge.

def give_good_tip(bill):
    return bill + (bill * 0.15)

print(give_good_tip(25.13))

As you can see it is quite easy to use percentages if you remember this simple trick.


#6