Browse Source

Formating

pull/3/head
Jure Šorn 6 years ago
parent
commit
d0d7bd1459
1 changed files with 3 additions and 0 deletions
  1. 3
      README.md

3
README.md

@ -124,6 +124,7 @@ from_inclusive = <range>.start
to_exclusive = <range>.stop to_exclusive = <range>.stop
``` ```
Enumerate Enumerate
--------- ---------
```python ```python
@ -180,6 +181,7 @@ def step(start, step):
yield start yield start
start += step start += step
``` ```
```python ```python
>>> stepper = step(10, 2) >>> stepper = step(10, 2)
>>> next(stepper), next(stepper), next(stepper) >>> next(stepper), next(stepper), next(stepper)
@ -192,6 +194,7 @@ Type
```python ```python
<type> = type(<el>) # <class 'int'> / <class 'str'> / ... <type> = type(<el>) # <class 'int'> / <class 'str'> / ...
``` ```
```python ```python
from numbers import Number, Integral, Real, Rational, Complex from numbers import Number, Integral, Real, Rational, Complex
is_number = isinstance(<el>, Number) is_number = isinstance(<el>, Number)

|||||||
100:0
Loading…
Cancel
Save