Previous topic

sknano.core.rezero_array

Next topic

sknano.core.take

sknano.core.cyclic_pairs

sknano.core.cyclic_pairs(iterable)[source][source]

Generate a cyclic list of all subsequence pairs in iterable.

Returns:list

Examples

>>> cyclic_pairs('ABC')
[('A', 'B'), ('B', 'C'), ('C', 'A')]