Ciao!
Qualcuno mi spiega come e' possibile che questo script:
1 #!/usr/bin/python
2 import sys
3 import getopt
4
5 quiet = False
6
7 def main():
8 print quiet
9 optlist, args = getopt.getopt(sys.argv[1:], 'q', ['--quiet'])
10
11 for o,a in optlist:
12 if o in ('-q',
Andrea Gasparini ha scritto:
> Ciao!
> Qualcuno mi spiega come e' possibile che questo script:
>
> 1 #!/usr/bin/python
> 2 import sys
> 3 import getopt
> 4
> 5 quiet = False
> 6
> 7 def main():
> 8 print quiet
> 9 optlist, args = getopt.getopt(sys.argv[1:], 'q', ['--quiet'])
> 1
Manlio Perillo ha scritto:
> Andrea Gasparini ha scritto:
>> Ciao!
>> Qualcuno mi spiega come e' possibile che questo script:
>>
>> 1 #!/usr/bin/python
>> 2 import sys
>> 3 import getopt
>> 4
>> 5 quiet = False
>> 6
>> 7 def main():
>> 8 print quiet
>> 9 optlist, args = getopt.ge