Skip to main content

All Questions

11 votes
5 answers
3k views

Lazy transform in C++

I have the following Python snippet that I would like to reproduce using C++: from itertools import count, imap source = count(1) pipe1 = imap(lambda x: 2 * x, source) pipe2 = imap(lambda x: x + 1, ...
bruno nery's user avatar
  • 2,052