summaryrefslogtreecommitdiff
path: root/python
diff options
context:
space:
mode:
authorPatrick Simianer <pks@pks.rocks>2018-08-17 18:20:54 +0200
committerPatrick Simianer <pks@pks.rocks>2018-08-17 18:20:54 +0200
commitb78965221808a3f688c1da12a1179db1bbbf1ad5 (patch)
treec08676943f9c2208749ef6a3a840053e97ffddd3 /python
parentee24c6445d418219a767525f06254930b0c6cb36 (diff)
kwargs1
Diffstat (limited to 'python')
-rwxr-xr-xpython/kwargs1.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/python/kwargs1.py b/python/kwargs1.py
new file mode 100755
index 0000000..0917965
--- /dev/null
+++ b/python/kwargs1.py
@@ -0,0 +1,10 @@
+def a(x, y=None, z=3):
+ print(x)
+ print(y)
+ print(z)
+
+def b(*args, **kwargs):
+ return a(*args, **kwargs)
+
+b(2, y=-1, z=1)
+