MCPcopy Create free account
hub / github.com/algorithm-archivists/algorithm-archive / main

Function main

contents/IFS/code/rust/IFS.rs:22–36  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

20}
21
22fn main() {
23 let shapes = vec![
24 Point{x: 0., y: 0.},
25 Point{x: 0.5, y: 0.75_f64.sqrt()},
26 Point{x: 1., y: 0.},
27 ];
28
29 let mut out = String::new();
30
31 for point in chaos_game(10_000, shapes) {
32 out += format!("{}\t{}\n", point.x, point.y).as_str();
33 }
34
35 std::fs::write("./sierpinski.dat", out).unwrap();
36}

Callers

nothing calls this directly

Calls 1

chaos_gameFunction · 0.70

Tested by

no test coverage detected