pep8 värk
This commit is contained in:
parent
af2ded0767
commit
1588e7d727
2
.gitignore
vendored
2
.gitignore
vendored
@ -34,3 +34,5 @@ nosetests.xml
|
|||||||
.mr.developer.cfg
|
.mr.developer.cfg
|
||||||
.project
|
.project
|
||||||
.pydevproject
|
.pydevproject
|
||||||
|
|
||||||
|
.ropeproject
|
||||||
|
11
elevant.py
11
elevant.py
@ -3,19 +3,19 @@
|
|||||||
# Kuule osta elevant ära #
|
# Kuule osta elevant ära #
|
||||||
# #
|
# #
|
||||||
# #
|
# #
|
||||||
#Author: Arti Zirk <arti.zirk@gmail.com> #
|
# Author: Arti Zirk <arti.zirk@gmail.com> #
|
||||||
#License: Do What the Fuck You Want to Public License #
|
# License: Do What the Fuck You Want to Public License #
|
||||||
# #
|
# #
|
||||||
########################################################################
|
########################################################################
|
||||||
|
|
||||||
import sys
|
import sys
|
||||||
|
|
||||||
asi = " ".join(sys.argv[1:])
|
asi = " ".join(sys.argv[1:])
|
||||||
if not asi.strip(): # argumente pole, kasuta vaikimisi asja
|
if not asi.strip(): # argumente pole, kasuta vaikimisi asja
|
||||||
asi = "elevant"
|
asi = "elevant"
|
||||||
|
|
||||||
|
|
||||||
abi="""Kuule osta elevant ära
|
abi = """Kuule osta elevant ära
|
||||||
Kasutus: main.py [asi | -h | --abi]"""
|
Kasutus: main.py [asi | -h | --abi]"""
|
||||||
if asi in ("-h", "--abi",):
|
if asi in ("-h", "--abi",):
|
||||||
print(abi)
|
print(abi)
|
||||||
@ -25,7 +25,8 @@ print("> Kuule osta " + asi + " ära!")
|
|||||||
while True:
|
while True:
|
||||||
try:
|
try:
|
||||||
vastus = input("< ").lower()
|
vastus = input("< ").lower()
|
||||||
print("> Seda räägivad kõik, et " + vastus + " aga osta "+ asi +" ära!")
|
print("> Seda räägivad kõik, et {} aga osta {} ära!".format(vastus,
|
||||||
|
asi))
|
||||||
except (EOFError, KeyboardInterrupt) as e:
|
except (EOFError, KeyboardInterrupt) as e:
|
||||||
print("\033[4D> Mis sul viga on, et " + asi + " ei taha ??")
|
print("\033[4D> Mis sul viga on, et " + asi + " ei taha ??")
|
||||||
exit()
|
exit()
|
||||||
|
Loading…
Reference in New Issue
Block a user