Skip to content
Advertisement

Tag: emacs

Python in emacs: __name__ == ‘__main__’, but somehow not

I am coding python in emacs. However, somehow the python interpreter running in emacs manages to surprise me. If I write in an emacs buffer, and tell emacs to start an interpreter and run the content of this buffer, I get a buffer containing (Both __main__ and True are the outputs from the print statement; the python buffer always displays

Advertisement