Homework question is asking me to write a program that would output True if an integer is odd and has the number "0" in the middle of it. I figured out how to get it to print True if a number is odd but can't figure out how to detect if the number 0 is in the middle.
I've figured out the first condition which would be detecting if it's odd.
input: def is_cyclops(n): if len(str (n)) % 2 != 0: return True return False print (is_cyclops(11011)) output: True I want to know how to get the code to detect the number 0 in the middle.