I cannot differentiate two different string values when I input them into an if/elif/else statement. In my code, the user is asked if they would like to tip or not when ordering from a menu. But it always shows up as asking for the value of the tip even when I say no. I wanted to know what I was doing wrong and how to change it. Thanks in advance.
tax = (selection * 0.05)
price_without_tip = float(selection + (tax * selection))
tip_Selection = str(input('Enter the Word Yes or No exactly to choose if you would like
to tip: '))
percent_Or_Fixed = input('Enter the word Percent or Fixed exactly to choose your
preferred form of Tip: ')
if tip_Selection == 'Yes':
print(percent_Or_Fixed)
elif tip_Selection == 'No':
print(price_without_tip)
else:
print('Invalid Response. Please Restart Order')
percent = 0.18
fixed = 2.00
if percent_Or_Fixed == 'Percent':
print ((selection + (selection * percent) + tax))
elif percent_Or_Fixed == 'Fixed':
print(selection + fixed + tax)