Slice off items in iterable found at index n.

Parameters: iterable – iterable n (int) – index of some items in iterable default – default returned if nothing is found at n iterator of items
```>>> from blade.xslice import xat
>>> # default behavior
>>> xat([5, 4, 3, 2, 1], 2)
3
>>> # return default value if nothing found at index
>>> xat([5, 4, 3, 2, 1], 10, 11)
11
```

Randomly slice off one items in iterable.

Parameters: iterable – iterable
```>>> from blade.xslice import xchoice
>>> list(xchoice([1, 2, 3, 4, 5, 6]))
3
```

Slice one iterable items in iterable into n iterable items in iterable.

Parameters: iterable – iterable n (int) – number of items in iterable per slice fill – value to pad out incomplete iterables iterator of items
```>>> from blade.xslice import xdice
>>> list(xdice(['moe', 'larry', 'curly', 30, 40, 50, True], 2, 'x'))
[('moe', 'larry'), ('curly', 30), (40, 50), (True, 'x')]
```

Slice off n things from the starting end of iterable or just the first items in iterable.

Parameters: iterable – iterable n (int) – number of items in iterable iterator of items
```>>> from blade.xslice import xfirst
>>> # default behavior
>>> list(xfirst([5, 4, 3, 2, 1]))
[5]
>>> # first things from index 0 to 2
>>> list(xfirst([5, 4, 3, 2, 1], 2))
[5, 4]
```

Slice off every items in iterable except the last iterable.

Parameters: iterable – iterable iterator of items
```>>> from blade.xslice import xinitial
>>> list(xinitial([5, 4, 3, 2, 1]))
[5, 4, 3, 2]
```

Slice off n things from the tail end of items in iterable or just the last items in iterable.

Parameters: iterable – iterable n (int) – number of items in iterable to slice off iterator of items
```>>> from blade.xslice import xlast
>>> # default behavior
>>> list(xlast([5, 4, 3, 2, 1]))[0]
1
>>> # fetch last two things
>>> list(xlast([5, 4, 3, 2, 1], 2))
[2, 1]
```

Slice off every items in iterable except the first item.

Parameters: iterable – iterable iterator of items
```>>> from blade.xslice import xrest
>>> list(xrest([5, 4, 3, 2, 1]))
[4, 3, 2, 1]
```
```>>> from blade.xslice import xsample