I'm just an amateur at python here but I was trying to code a short program that can answer questions based on inputs that match strings in a list. Here is my code below:
helloInputs = ["hello", "hi", "hey there", "yo", "hello", ]
howAreInputs = ["how are you", "how are you doing", "how you doing", "how are ya", "sup"]
ageInputs = ["how old are you", "what is your age", "age", "when were you born"]
a = raw_input("Type something here: ")
if a.upper() or a.lower() in helloInputs:
print("Hello there!")
if a.upper() or a.lower() in ageInputs:
print("My name is PySpeechBot. I was made by developer Nicholas A. on June 6, 2020")
if a.upper() or a.lower() in howAreInputs:
print("Im feeling good today! This is actually the only response I am programmed to say back...")
Anyways, the problem I am having is that when I input something simple like 'Hello', it will respond back with all possible answers instead of just one. Again, not the best programmer here, but if this could be fixed, i would appreciate it.