Im new to this so Im sorry if this isn't the best way to ask the question...
here is the code -
import sys
print("What is ur name?")
name = sys.stdin.readline()
answer = "jack"
if name is answer :
print("ur awesome")
exit();
right now when I run it in cmd I don't get anything printed even though I input - jack? thank you in advance
==instead ofis.sys.stdin.readline(). It will preserve newline. So if you enterjack, it will actually bejack\n. So,answer == "jack"will be False when it should really be true. You are better off usinginput()instead.sys.stdin.readline(), you wantanswer==name.strip()otherwise useinput()