I did not think it was possible to mess up the first program following instructions, but I managed to.
Here are instructions I followed:
Start your editor, type the following program and save it as helloworld.py.
print 'Hello World'
Run this program by opening a shell prompt and run the command python helloworld.py. If you are using PythonWin, use the menu File → Run.
The output is as shown below:
$ python helloworld.py
Hello World
I get an error when I run the command in terminal...
NOTE- Edited error message, pasted wrong
>>> python helloworld.py
File "<stdin>", line 1
python helloworld.py
^
SyntaxError: invalid syntax
EDIT- The carrot appears in terminal pointing to the d, but in the thread it does not seem to get spacing right
I have the file saved as helloworld.py on the desktop, and have no idea why this will not work....
Just entering "print 'hello world'" works fine in terminal
Bookmarks