[Python] Can't Open File [Errno 2 ] No such file or directory

Discussão em 'Python' iniciado por Stack, Julho 23, 2025.

  1. Stack

    Stack Membro Participativo

    I am new to coding and trying to run a python code in VS Code using code runner but it doesn't work, I think the issue is that code runner runs C:/c/-------- which doesn't exist in my directory, but I don't know how to go about solving it. screenshot of terminal when I try to run

    Code in terminal:

    PS C:\Users\Kevin> python -u "/c/Users/Kevin/Desktop/Coding/Python/testing/hello.py"

    C:\Python\Python39\python.exe: can't open file 'C:\c\Users\Kevin\Desktop\Coding\Python\testing\hello.py': [Errno 2] No such file or directory

    Continue reading...

Compartilhe esta Página