After hours of searching, it was finally solved
If it is Python 2.7, the required nltk version is 3.0
pip install nltk==3.0
Original text: https://stackoverflow.com/questions/61560956/invalid-syntax-on-importing-nltk-in-python-2-7
Similar Posts:
- Getaddrinfo failed error encountered while nltk. Download()
- Nltk’s word splitter Punkt: SSL problem, unable to download
- Importerror: no module named yaml solution [How to Solve]
- [Solved] Shell Error: syntax error: invalid arithmetic operator (error token is “
- How to Solve Centos Yum Error: No module named yum
- Debian pip3 ImportError: cannot import name ‘IncompleteRead’ [How to Solve]
- Python: How to Solve ImportError: No module named wx
- PyCrypto Install error: Unable to find vcvarsall.bat
- Docker Django: underlying buffer has been detached [How to Solve]
- Pycharm ImportError: No module named selenium [How to Solve]