Metadata-Version: 2.1
Name: bootle
Version: 0.1.0
Summary: “Should array indices start at 0 or 1? My compromise of 0.5 was rejected
Home-page: https://github.com/osteele/bootle
License: UNKNOWN
Author: Oliver Steele
Author-email: steele@osteele.com
Requires-Python: >=3.0
Description-Content-Type: text/markdown
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: 3.6

# Bootle: Half-Index Lists for Python

“Should array indices start at 0 or 1? My compromise of 0.5 was rejected
without, I thought, proper consideration.” -- Stan Kelly-Bootle

## Installation

```bash
pip3 install bootle
```

## Usage

```python
from bootle import List

xs = List([1, 2, 3])
assert xs[0.5] == 1
assert xs[:1.5] == [1]
xs[1.5] == 2
assert xs.index(2) == 1.5
```

## References

* ["Why numbering should start at zero"](https://www.cs.utexas.edu/users/EWD/transcriptions/EWD08xx/EWD831.html), Edsger W. Dijkstra, 1982
* [Why Numbering Should Start At Zero](http://wiki.c2.com/?WhyNumberingShouldStartAtZero), WikiWikiWeb
* [Why Numbering Should Start At One](http://wiki.c2.com/?WhyNumberingShouldStartAtOne),  WikiWikiWeb
* [Zero-based numbering](https://en.wikipedia.org/wiki/Zero-based_numbering), Wikipedia

## License

WTFPL

