0

Hi I am trying to ask the user to input a binary number and checking to see if

the input contains 0's and 1's. If not, I want to inform the user that the input was invalid and ask them to retry.

Any help to fix my code would be greatly appreciated.

```
binary = int(raw_input("Enter a binary number:"))
for i in range(binary):
if (binary != 0 or binary != 1):
print "Invalid input"
binary = int(raw_input("Enter a binary number:"))
```