diff --git a/kjg/python-the-hard-way/e13.py b/kjg/python-the-hard-way/e13.py new file mode 100644 index 0000000..f8b7fe8 --- /dev/null +++ b/kjg/python-the-hard-way/e13.py @@ -0,0 +1,8 @@ +from sys import argv +# read the WYSS section for how to run this +script, first, second, third = argv + +print("The script is called:", script) +print("Your first variable is:", first) +print("Your second variable is:", second) +print("Your third variable is:", third) diff --git a/kjg/python.org b/kjg/python.org index 64a4a71..8ef9d17 100644 --- a/kjg/python.org +++ b/kjg/python.org @@ -77,3 +77,5 @@ how to use \ (using special chracter) how to use key input **** ex12 how to use key input with print +**** ex13 +how to use an argument when you run script