I know that ==
checks the values of the operands, and is
checks the reference to the same object. However, I can't seem to figure out why the following codes behave differently.
Code1:
i=input()
#Let's say input is Hello
i is "Hello" #Returns False
Code2:
i="Hello"
i is "Hello" #Returns True
Why are the outputs in the two cases different? Isn't assigning "Hello" same as inputting "Hello"?