Hi everyone, this is very basic/beginner question.
I'm reading TXT file, two words per line that are separated by TAB:
question, rightAnswer = line.strip().split('\t')
I would like to use TXT file that it would be separated by coma.
How do I change that line of code?
I tried these two versions but it is not working:
question, rightAnswer = line.strip().split('\c') # c for coma?
question, rightAnswer = line.strip().split('\,') # , for coma?
I have latest Python version.
_______________________________________________
Tutor maillist - [email protected]
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor