Writing test page

This commit is contained in:
2026-02-10 17:04:48 +03:00
parent fe75d7de23
commit 87a9fae91a
4 changed files with 143 additions and 12 deletions
+10 -4
View File
@@ -180,6 +180,14 @@ impl KanaSet {
}
pub fn next(&mut self) -> (String, String) {
let current_set = self.list();
let mut rand = rand::rng();
let index: u32 = rand.random();
current_set[index as usize % current_set.len()].clone()
}
pub fn list(&self) -> Vec<(String, String)> {
let mut current_set: Vec<(String, String)> = Vec::new();
for i in 0..10 {
@@ -189,10 +197,8 @@ impl KanaSet {
});
}
}
let mut rand = rand::rng();
let index: u32 = rand.random();
current_set[index as usize % current_set.len()].clone()
current_set
}
}