From 9c4ca96e8ea11cb6f17d4059d5095dadee659881 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mert=20G=C3=B6r?= Date: Sat, 5 Aug 2023 16:27:48 +0300 Subject: [PATCH] =?UTF-8?q?=C3=87ift=20Y=C4=B1ld=C4=B1zl=C4=B1=20Parametre?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- python-temel/cift.yildizli.parametre.py | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 python-temel/cift.yildizli.parametre.py diff --git a/python-temel/cift.yildizli.parametre.py b/python-temel/cift.yildizli.parametre.py new file mode 100644 index 0000000..1e2d044 --- /dev/null +++ b/python-temel/cift.yildizli.parametre.py @@ -0,0 +1,15 @@ +def foo(f): + print('foo') + + def g(*args, **kwargs): + print('g') + f(*args, **kwargs) + + return g + +@foo +def bar(a, b, c, **kwargs): + print(f'bar: {a}, {b}, {c}, {kwargs}') + +bar(10, 20, 30, xx=100, yy=200) +bar(50, 60, 70, zz=300, kk=400)