def arg_printer(a, b, *args, option=True, **kwargs): print(a, b) print(args) print(option) print(kwargs) arg_printer(1, 4, 6, 5, param1=5, param2=6) # prints: # 1 4 # (6, 5) # True # {'param1': 5, 'param2': 6}
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter