Tidy up and add's slides on remotes
This commit is contained in:
parent
94607bbdea
commit
312d654ea8
5 changed files with 315 additions and 61 deletions
25
code-examples/python-with-cow.py
Normal file
25
code-examples/python-with-cow.py
Normal file
|
@ -0,0 +1,25 @@
|
|||
#!/usr/bin/env python
|
||||
|
||||
import sys
|
||||
|
||||
def cat():
|
||||
print("Meow")
|
||||
|
||||
def dog():
|
||||
print("Woof")
|
||||
|
||||
def cow():
|
||||
print("Moo")
|
||||
|
||||
def main():
|
||||
if len(sys.argv) > 1 and sys.argv[1] == "cat":
|
||||
cat()
|
||||
elif len(sys.argv) > 1 and sys.argv[1] == "dog":
|
||||
dog()
|
||||
elif len(sys.argv) > 1 and sys.argv[1] == "cow":
|
||||
cow()
|
||||
else:
|
||||
print("HELLO WORLD")
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
Loading…
Add table
Add a link
Reference in a new issue