So i have a program called lonesum(a,b,c) that needs to add the 3 numbers entered together only if they are input once. so lonesum(1,2,3) would return 6 but lonesum(1,1,3) would return 3. I have that part. What i need help with is getting a statement to work that will return an error if the user enters anything that isn't an integer i.e. lonesum(.5,2,3) will return error. so far i have this while statement which i thought would work but doesn't,:
while (a,b,c) != int:
print("Error")
return None
while a==b==c:
return 0
while a==b:
return c
while b==c:
return a
while a==c:
return b
while a!=b!=c:
sum1=(a+b+c)
return sum1
(That is the rest of my code, that is the part that works)
My problem is the != doesn't work and I'm not sure what to do. Any suggestions?