This is my code
salary = input("Please enter your salary at: ") things = [["iphone","5000"],["mac pro","12000"],["coffee","31"],["book","81"],["bike","800"]] while True :
Error type is
File “C:/Users/googol/PycharmProjects/untitled/ shopping.py “, line 5
^
SyntaxError: unexpected EOF while parsing
Process finished with exit code 1
Solution: because the code I wrote constitutes an infinite loop, so the error, the solution is to add the end condition
Similar Posts:
- How to Solve Python Error: “HTTP Error 403: Forbidden”
- [Solved] Python 3.8 Install pyaudio Error: pip3 install pyaudio error: Microsoft Visual C++ 14.0 or greater is required.
- Python read CSV file prompt “line contains null byte” error
- Solve the problem of attributeerror: module ‘Matplotlib’ has no attribute ‘verb
- TypeError at /index.html/ ‘method’ object is not subscriptable
- [Solved] Importerror: DLL load failed while importing mtrand: the specified program could not be found.
- Django Run Error: RuntimeError: maximum recursion depth exceeded while calling a Python object
- Swift 3.0: How to solve the problem of timer circular reference
- Unexpected token ‘ in JSON at position 2 at JSON.parse