On 01/06/2015 09:30, Steven D'Aprano wrote:
> How do you run it in Windows 7? The hashbang line
>
> #!/usr/bin/python
>
> is for Linux and Unix, and won't work on Windows. So you must be doing
> something to execute the file. What is that?
Actually, it will for anywhere with a recent Python
On Monday 01 June 2015 17:50, fl wrote:
> Hi,
>
> When I try the following (They are saved in a main.py file)
>
> #!/usr/bin/python
> print r'C:\\nowhere'
Aside: Don't use raw strings for file names. They aren't intended for file
names, and while they will *usually* work, some day you will try
fl writes:
> When I run the following command in a Python 2.7.9 Shell on Windows 7,
>
> print r'C:\\nowhere'
>
> It has error:
>
print r'C:\\nowhere'
> SyntaxError: invalid syntax
>
> What is the problem? Why does it behave different at .py file
> and Python Shell?
Have you executed the foll