* @example take_last.cpp **/
| 6 | * @example take_last.cpp |
| 7 | **/ |
| 8 | int main() |
| 9 | { |
| 10 | //! [take_last] |
| 11 | rpp::source::just(0, 1, 2, 3, 4, 5, 6, 7, 8, 9) |
| 12 | | rpp::ops::take_last(2) |
| 13 | | rpp::ops::subscribe([](int v) { std::cout << v << " "; }); |
| 14 | // Output: 8 9 |
| 15 | //! [take_last] |
| 16 | return 0; |
| 17 | } |