3#include "generator.hpp"
An arbitrary generator for producing sequential results on-the-fly.
Definition generator.hpp:71
generator(const S &initial, std::function< const std::optional< T >(S &)> lambda)
Constructor with an initial state.
Definition generator.hpp:93
generator< T, countedState > skip(long count) noexcept
Skips a certain number of items from the generator.
Definition generator.hpp:296
long count()
Consume and discard all items from the generator, getting only the number of items generated.
Definition generator.hpp:127
A sentinel that stops a numeric generator when the value reaches a certain point.
Definition sentinel.hpp:10
Section containing core functions and classes.
generator< long, long > range(long begin, long end, long step=1) noexcept
Generate a sequence of integers in a specified range.
A specialized state for generator::enumerate().
Definition generator.hpp:80