Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- fn hash_block(data: &String, nonce: i64) -> String {
- let formatted_string = format!("{}{}", data, nonce);
- let hashable_string = &formatted_string;
- let mut hasher = Sha256::new();
- hasher.input_str(hashable_string);
- let result = hasher.result_str();
- return result;
- }
Add Comment
Please, Sign In to add comment