[Solved] How will I convert this int into a string in an if statement? [closed]


You can say:

tax2 = int( input("How Much Will You Tax Per Person In Dollars? ") )

If you’re sure the input won’t contain decimals. If you’re not sure, and want to keep the decimal value, you could use:

tax2 = float( input("How Much Will You Tax Per Person In Dollars? ") )

Or use integers, but play it safe, with

taxf = round( float( input("How Much Will You Tax Per Person In Dollars? ") ) )
tax2 = int( taxf )

solved How will I convert this int into a string in an if statement? [closed]