Commit 62317df8 authored by Lingling Jin (lij313)'s avatar Lingling Jin (lij313)
Browse files

update ex19

parent 12ce4521
bash-4.4$ diff ex18.py ex19.py
3,4c3,18
< for Arg in sys.argv:
< print ( Arg )
---
>
> # create a multi-line string
> Usage="""
> Usage:
> ex20.py [arguments]
> """
>
> # if no command-line arguments, output a usage message.
> # Otherwise, print the command line arguments
> if len( sys.argv ) == 1:
> print ( Usage )
> else:
> # we need to skip over sys.argv[0]
> ArgList = sys.argv[1:]
> for Arg in ArgList:
> print ( Arg )
bash-4.4$
bash-4.4$ chmod u+x ex19.py
bash-4.4$
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment