* @example take.cpp **/
| 6 | * @example take.cpp |
| 7 | **/ |
| 8 | int main() // NOLINT(bugprone-exception-escape) |
| 9 | { |
| 10 | //! [take] |
| 11 | rpp::source::from_iterable(std::vector{0, 1, 2, 3, 4}) |
| 12 | | rpp::operators::take(2) |
| 13 | | rpp::operators::subscribe([](int v) { std::cout << v << " "; }); |
| 14 | // Output: 0 1 |
| 15 | //! [take] |
| 16 | return 0; |
| 17 | } |
nothing calls this directly
no test coverage detected