putPut the code inside a function and it won't run until you call the function. You should have a main function in your main.pymain.py. with the statement:
if __name__ == '__main__': main()
thenThen, if you call "python main.py"python main.py the main()main() function will run. If you import main.pymain.py, it will not. Also, you should probably rename main.pymain.py to something else for clarityclarity's sake.
put the code inside a function and it won't run until you call the function. You should have a main function in your main.py. with the statement:
if __name__ == '__main__': main()
then, if you call "python main.py" the main() function will run. If you import main.py, it will not. Also, you should probably rename main.py to something else for clarity sake.
Put the code inside a function and it won't run until you call the function. You should have a main function in your main.py. with the statement:
if __name__ == '__main__': main()
Then, if you call python main.py the main() function will run. If you import main.py, it will not. Also, you should probably rename main.py to something else for clarity's sake.
put the code inside a function and it won't run until you call the function. You should have a main function in your main.py. with the statement:
if __name__ === '__main__': main()
then, if you call "python main.py" the main() function will run. If you import main.py, it will not. Also, you should probably rename main.py to something else for clarity sake.
put the code inside a function and it won't run until you call the function. You should have a main function in your main.py. with the statement:
if __name__ = '__main__': main()
then, if you call "python main.py" the main() function will run. If you import main.py, it will not. Also, you should probably rename main.py to something else for clarity sake.
put the code inside a function and it won't run until you call the function. You should have a main function in your main.py. with the statement:
if __name__ == '__main__': main()
then, if you call "python main.py" the main() function will run. If you import main.py, it will not. Also, you should probably rename main.py to something else for clarity sake.
put the code inside a function and it won't run until you call the function. You should have a main function in your main.py. with the statement:
if __name__ = '__main__': main()
then, if you call "python main.py" the main() function will run. If you import main.py, it will not. Also, you should probably rename main.py to something else for clarity sake.