We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e328bd5 commit 1bff274Copy full SHA for 1bff274
1 file changed
implement-cowsay/cow.py
@@ -0,0 +1,13 @@
1
+
2
+import argparse
3
+import cowsay
4
5
+parser = argparse.ArgumentParser(
6
+ prog="cowsay",
7
+ description="Make animals say things",
8
+)
9
+parser.add_argument("--animal", default="cow", help="The animal to be saying things.", choices=cowsay.char_names)
10
+parser.add_argument("message", nargs="+", help="The message to say.")
11
+args = parser.parse_args()
12
13
+cowsay.char_funcs[args.animal](" ".join(args.message))
0 commit comments