Error when importing programs IDLE
Question: Im new to Python but Im getting on pretty well, however I cannot seem to
import save programs into IDLE. Could someone assist me where that is
concerned, please. This is one of the errors no matter how simple the program
is:

    
    
    >>> import dinner
    
    Traceback (most recent call last):
      File "<pyshell#17>", line 1, in <module>
        import dinner
      File "C:\Python25\dinner.py", line 1
        Python 2.5.4 (r254:67916, Dec 23 2008, 15:10:54) [MSC v.1310 32 bit (Intel)] on win32
                 ^
    SyntaxError: invalid syntax
    


Answer: This is the error you would get if your `dinner.py` program actually started
with the line

    
    
    Python 2.5.4 (r254:67916, Dec 23 2008, 15:10:54) [MSC v.1310 32 bit (Intel)] on win32
    

But that's not a line of valid Python code, that's the message that the
interpreter gives on startup. For example, mine says

    
    
    ~/coding$ python
    Python 2.7.3 (default, Aug  1 2012, 05:16:07) 
    [GCC 4.6.3] on linux2
    Type "help", "copyright", "credits" or "license" for more information.
    >>>
    

and it's then that I start typing things like `print 2+2`, etc. You can open
`dinner.py` in IDLE and remove any parts which look like this welcome message
at the start.

Incidentally, I see you're using Python 2.5.4. This is pretty old now, and a
lot of neat things have been added since. I would suggest switching to 2.7.3
instead.

