pub fn canonical_code_book(code_lengths: &[(u8, u8)]) -> CodeBook