pub fn find_single_byte_xor(b: Vec<Vec<u8>>) -> Result<Vec<u8>, hex::FromHexError> {
    let (mut score, mut result) = (0.0, Vec::new());

    for cipher in b {
        let (s, _, m) = single_byte_xor(&cipher)?;

        if s > score {
            score = s;
            result = m;
        }
    }

    Ok(result)
}
/// Find single byte xor
///
/// Solution for problem 4 from set1: <https://cryptopals.com/sets/1/challenges/4>
Find single byte xor
Solution for problem 4 from set1.
Find single byte xor Solution for problem 4 from set1 .
pub fn find_single_byte_xor(b: Vec<Vec<u8>>) -> Result<Vec<u8>, hex::FromHexError> {
    let (mut score, mut result) = (0.0, Vec::new());
    for cipher in b {
        let (s, _, m) = single_byte_xor(&cipher)?;
        if s > score {
            score = s;
            result = m;
        }
    }
    Ok(result)
}
pub fn find_single_byte_xor ( b : Vec < Vec < u8 > > ) -> Result < Vec < u8 > , hex :: FromHexError > { let ( mut score , mut result ) = ( 0.0 , Vec :: new ( ) ) ; for cipher in b { let ( s , _ , m ) = single_byte_xor ( & cipher ) ? ; if s > score { score = s ; result = m ; } } Ok ( result ) }
Find single byte xor
Solution for problem 4 from set1: <https://cryptopals.com/sets/1/challenges/4>
Find single byte xor Solution for problem 4 from set1 : <https : // cryptopals . com / sets / 1 / challenges / 4 >
b
Vec<Vec<u8>>