feat: implement first task as file

This commit is contained in:
0xalivecow 2024-10-18 20:28:30 +02:00
parent 27acd0a531
commit 64fe182fc3
No known key found for this signature in database
9 changed files with 70 additions and 19 deletions

View file

@ -0,0 +1,7 @@
use crate::utils::poly::{self, coefficient_to_binary};
use base64::prelude::*;
use serde_json::Value;
pub fn poly2block(coefficients: Vec<u8>) -> String {
BASE64_STANDARD.encode(poly::coefficient_to_binary(coefficients).to_ne_bytes())
}