Data commit

This commit is contained in:
Ingy döt Net 2023-07-01 11:58:00 -04:00
parent 7387c8f97b
commit cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions

View file

@ -0,0 +1,26 @@
extern crate rand;
use rand::Rng;
fn random_cell<R: Rng>(rng: &mut R) -> u32 {
// Anything between 0 and 10_000 (exclusive) has 4 digits or fewer. Using `gen_range::<u32>`
// is faster for smaller RNGs. Because the parameters are constant, the compiler can do all
// the range construction at compile time, removing the need for
// `rand::distributions::range::Range`
rng.gen_range(0, 10_000)
}
fn main() {
let mut rng = rand::thread_rng(); // Cache the RNG for reuse
println!("<table><thead><tr><th></th><td>X</td><td>Y</td><td>Z</td></tr></thead>");
for row in 0..3 {
let x = random_cell(&mut rng);
let y = random_cell(&mut rng);
let z = random_cell(&mut rng);
println!("<tr><th>{}</th><td>{}</td><td>{}</td><td>{}</td></tr>", row, x, y, z);
}
println!("</table>");
}

View file

@ -0,0 +1,5 @@
<table><thead><tr><th></th><td>X</td><td>Y</td><td>Z</td></tr></thead>
<tr><th>0</th><td>7101</td><td>9111</td><td>3446</td></tr>
<tr><th>1</th><td>426</td><td>9518</td><td>611</td></tr>
<tr><th>2</th><td>9693</td><td>419</td><td>4878</td></tr>
</table>