I have the following python code:
#!/usr/bin/env python3 import sys for line in sys.stdin: line = line.strip().split(',') airline_id = line origin = line dest = line print(airline.id) print(type(airline.id)) test = "WN" print(type(test)) print(airline==test)
that out puts:
"WN" <class 'str'> <class 'str'> False
Why does it do this? Why are these two not equal? Is there any difference between python string and command-line string?