from functools import partial def f(a, b=2): print a, b f1 = partial(f, 'fixed_a') f1(b=777) # fixed_a 777 f2 = partial(f, b='fixed_b') f2(777) # 777 fixed_b
Post a Comment
No comments:
Post a Comment