I'm taking an online class and there are assignments. The on i'm working now has me comparing 3 numbers together to look for a match. Works fine with int's but when I pass a "two" into the function instead of a 2, i'm not able to compare and if I try to convert it, i'm not able to either.
Any ideas?
boolHomework = homework3Bonus(1,2,"two")
def homework3Bonus(a,b,c):
print("The type of input is", type(c))
strA = a
strB = b
strC = int(c) #this isn't working
print("The type of input is", type(a))
print("The strings are",strA,strB,strC)
if (strA == strB) or (strB == strC) or (strA == strC):
print("Match")
This gives the error strC = int(c) ValueError: invalid literal for int() with base 10: 'two'