On Jun 2, 8:50 am, Aldarion <[EMAIL PROTECTED]> wrote:
> On 6月2日, 上午8时05分, Peter Otten <[EMAIL PROTECTED]> wrote:
>
> > Aldarion wrote:
> > > for the little script
> > > #egg.py
> > > import sys
> > > for k,v in enumerate(sys.argv):
> > > print k,v
>
> > > it ignores the part after # on linux
> >
On 6月2日, 上午8时05分, Peter Otten <[EMAIL PROTECTED]> wrote:
> Aldarion wrote:
> > for the little script
> > #egg.py
> > import sys
> > for k,v in enumerate(sys.argv):
> > print k,v
>
> > it ignores the part after # on linux
> > below is the running output on windows and linux. no clue here.
>
> This
On Jun 2, 9:54 am, Aldarion <[EMAIL PROTECTED]> wrote:
> for the little script
> #egg.py
> import sys
> for k,v in enumerate(sys.argv):
> print k,v
>
> it ignores the part after # on linux
Perhaps "it" is the linux shell ...
> below is the running output on windows and linux. no clue here.
>
Aldarion wrote:
> for the little script
> #egg.py
> import sys
> for k,v in enumerate(sys.argv):
> print k,v
>
> it ignores the part after # on linux
> below is the running output on windows and linux. no clue here.
This has nothing to do with python, it's the shell that treats the # and
everyt
for the little script
#egg.py
import sys
for k,v in enumerate(sys.argv):
print k,v
it ignores the part after # on linux
below is the running output on windows and linux. no clue here.
D:\python\note>egg.py #test
0 D:\python\note\egg.py
1 #test
D:\python\note>egg.py for bar #spam egg
0 D:\pyt