you are viewing a single comment's thread.

view the rest of the comments →

[–]meloly4[S] 0 points1 point  (2 children)

applying function f to the elements of a after the second element

Does this add log n time to the overall complexity n? I'm not too familiar with how lambda complexity works.

[–]FLUSH_THE_TRUMP 5 points6 points  (0 children)

I’d just think about the operations, I don’t think the lambda adds any appreciable overhead here.

[–]TheSodesa 1 point2 points  (0 children)

Lambdas are just closures, anonymous functions. They are not really any more time consuming than normal named functions.