I am trying to run a .py script using IDLE which is in a different folder say D:\Python\Practice whereas my python is installed in C:\Python.
I changed the directory to D:\Python\Practice where the script was present through os.chdir command. Then I executed python xyz.py but it is throwing error.
import os
os.chdir("D:\Python\Practice")
python xyz.py
Syntax Error: Invalid Syntax