Hi, i'm just starting to learn python obviously and trying to get this program to run and it comes back as invalid syntax.
Python 2.6.
Print 'hello world' works fine, but i wrote the following program in text wrangler
#!/usr/bin/python
# Filename : helloworld.py
print 'Hello World'
then opened up a terminal and typed python helloworld.py and it comes back as invalid syntax.
I'm a right beginner at all this but i've tried numerous different ways of writing it with brackets, quotes, double quotes, spaces etc., and i cant' get anything to work... nor can i seem to find a definitive answer in my search on what python 2.6 syntax is.
So basically i feel stuck with no being able to continue working through the guide until i can get this program working. Any help be great.
Python 2.6.
Print 'hello world' works fine, but i wrote the following program in text wrangler
#!/usr/bin/python
# Filename : helloworld.py
print 'Hello World'
then opened up a terminal and typed python helloworld.py and it comes back as invalid syntax.
I'm a right beginner at all this but i've tried numerous different ways of writing it with brackets, quotes, double quotes, spaces etc., and i cant' get anything to work... nor can i seem to find a definitive answer in my search on what python 2.6 syntax is.
So basically i feel stuck with no being able to continue working through the guide until i can get this program working. Any help be great.