1

The lambda function is:

lambda x: x.split('=')

the partial function would look something like:

str.split('=')
duplode
  • 33,731
  • 7
  • 79
  • 150
Vasantha Ganesh
  • 4,570
  • 3
  • 25
  • 33

1 Answers1

1

Python has a function that does partial functions

from functools import partial

the partial function accepts callable function as the first argument and the rest are arguments to be applied to the function

partial(str.split, sep='=')
Aran-Fey
  • 39,665
  • 11
  • 104
  • 149
Vasantha Ganesh
  • 4,570
  • 3
  • 25
  • 33