Question:
there is main.py file in my folder and i written some code in it then i have created try.py file where i write some another code eg print(“Hi”) now when i try to tun try.py file i am unable to se Hi printed only my code from main.py file is getting runned not from the try.py file why so and how to fix?
Just click the ⋮ next to “Files” then click “Show hidden files”. Next click on the .replit file and finally you can change the entrypoint to whatever file you want to run, and in this case try.py.
You can directly run it from the shell using python [file_name].py. But if you want to run it by default, change the run command in .replit to 'python [file_name].py' as well as the entrypoint file.