pub fn check_sum<S: Into<String>>(&self, entropy: S) -> String {
        let hex = format!("{:x}", sha2::Sha256::digest(&hex::decode(entropy.into()).unwrap()));
        return hex
            .chars()
            .into_iter()
            .map(|c| format!("{:0>4}", format!("{:b}", c.to_digit(16).unwrap())))
            .collect::<String>()[..self.ent / 32]
            .to_string();
    }
// A checksum is generated by taking the first ENT / 32 bits of its SHA256 hash.
A checksum is generated by taking the first ENT / 32 bits of its SHA256 hash.
A checksum is generated by taking the first ENT / 32 bits of its SHA256 hash .
pub fn check_sum<S: Into<String>>(&self, entropy: S) -> String {
        let hex = format!("{:x}", sha2::Sha256::digest(&hex::decode(entropy.into()).unwrap()));
        return hex
            .chars()
            .into_iter()
            .map(|c| format!("{:0>4}", format!("{:b}", c.to_digit(16).unwrap())))
            .collect::<String>()[..self.ent / 32]
            .to_string();
    }
pub fn check_sum < S : Into < String > > ( & self , entropy : S ) -> String { let hex = format ! ( " " sha2 Sha256 digest ( hex decode ( entropy into ( ) ) unwrap ( ) ) ) ; return hex . chars ( ) . into_iter ( ) . map ( | c | format ! ( " " format ( " " c to_digit ( 16 ) unwrap ( ) ) ) ) . collect :: < String > ( ) [ .. self . ent / 32 ] . to_string ( ) ; }
A checksum is generated by taking the first ENT / 32 bits of its SHA256 hash.
A checksum is generated by taking the first ENT / 32 bits of its SHA256 hash .
&self
entropy
S