changed the bw_encode to handle sorting by sequences longer than one
symbol (e.g. inserting lines starting with 'as' between those starting
with 't' and 'hu').
the order argument must now be a list of bytes objects, functions
calling bw_encode still need to be updated
ordering by longer sequences is now possible
also changes the keys for the transition dict from a tuple of ints
(representing a byte each) to two bytes objects to prepare for
transitions between longer sequences

the achieved compression ratios are slightly different in at least one
case (the weighted badness with penalty is now slightly worse than the
handpicked order for book1), which is probably due to different
(pseudorandom) selection order for elements with the same metric value
(hash of int different than hash of bytes([int]))