Ive been stuck on this for a good chunk of time now and cant for the life of me figure out whats wrong with this code. But knowing me I have a feeling that the solution is so obvious that it’s gonna irritate me when i finally figure it out. any help? Thanks!
Hey there @bit6123061499 and welcome to the forums
Let’s take a look at what you are trying to do on the line the error refers to:
customer_one_tax = sales_tax * customer_one_total
Both of these values you have designated as a string with the use of parenthesis:
And though you can multiply a string by a number:
a = "a" b = a * 3 print(b) # prints aaa
You cannot multiply a string by a string, or an integer by a string:
a = "string" b = "another string" c = a * b TypeError: can't multiply sequence by non-int of type 'str'
but if i remove the parenthesis from .088 I get the same error and if i remove them from 0 i get a different error
Note though that the next error points to a different line. There are other variables in your program that are declared as strings, yet are being used as integers.
I figured it out but thank you! I was tunnel visioned on a few lines of code which explains why I was so stumped