aioplus.acount¶
- aioplus.acount(start=0, step=1)¶
Return evenly spaced values beginning with
start.- Parameters:
start (int, default 0) – The initial value. Must be an object supporting
object.__index__().step (int, default 1) – The difference between consecutive values. Must be an object supporting
object.__index__().
- Returns:
An infinite asynchronous iterable yielding integers, starting from
startand incremented bystep.- Return type:
AsyncIterable of int
Examples
>>> [num async for num in acount(start=23, step=4)] [23, 27, 31, 35, 39, 43, 47, ...]
Notes
Yields control to the event loop before producing each value.
See also