Why Bot message is not printing?
import random from random import choice class chatbot: #gives message according to the users analyzed message bot_greetings = ["Hola","Hey bro","hello","hey"] def __init__(self,analyze_message): self.analyze_message = analyze_message def chat_message(self): if self.analyze_message == True: bot_message = random.choice(bot_greetings) print('"_":'+bot_message) else: print("Sorry Man I can't analyze your last message") class user: #analyze user message def __init__(self,user_input): #self.user_input = user_input pass def analyze_message(self): user_greetings = ["hi","hello","hey","Hey bro"] if self.user_input in user_greetings: return True else: return False signal = analyze_message chatbot(signal) class chat_interface: #the whole chat interface will be shown by this class user_input = input('user:') user_message = user(user_input) def main(): chat_interface() if __name__ == '__main__': main()