Hey, I am very new to python, I am 13 years old. I want to be able to make a program the caculates the mean, meadian and mode. When i run the program, an input field pops up and says 'Does your list contain, a number or a string?' like I want it to, but when I type in something that is not one of valid field options: "String" or "string" or "STRING" or "s" or "S" or "str" or "Number" or "number" or "NUMBER" or "N" or "N" or "int" or "num", nothing happens, please tell me what I did wrong. Thanks :D Here is my code:
#----- Variables that I am using, including the list. -----# #False means num #True means string num_or_string = "" amount_numbers = [] List = [] I = "Does your list contain, a number or a string?" #----- Functions that I am using. -----# input(I) def NOS(): if I == "String" or "string" or "STRING" or "s" or "S" or "str": pass elif I == "Number" or "number" or "NUMBER" or "N" or "N" or "int" or "num": pass else: global I I = "You did not enter a valid field, :P Sorry." input(I) -- https://mail.python.org/mailman/listinfo/python-list