python default parameters depend on other paramters

Solutions on MaxInterview for python default parameters depend on other paramters by the best coders in the world

showing results for - "python default parameters depend on other paramters"
Alienor
03 Feb 2020
1def func(n=5.0, delta=None):  # other ways are not supported
2     if delta is None:
3         delta = n/10