4 ms·
Most functional languages don't have statements at all, and Python's anonymous functions can, as most, handle any single expression, regardless of complexity or
by dragonwriter 3y ago
Most functional languages don't have statements at all, and Python's anonymous functions can, as most, handle any single expression, regardless of complexity or size.
Python having a statement heavy syntax and making complex expressions (while possible) awkward is the problem with its anonymous functions, not the fact that its anonymous functions are limited to a single expression.
- heavyset_go 3y agoDefinitely, I'm looking at this from a superficial level of writing functional programming inspired code in imperative languages. JS makes this a bit more comfortable with its style of anonymous functions.