MCPcopy Create free account
hub / github.com/douchuan/algorithm / gen_random_data

Function gen_random_data

benches/sort.rs:231–235  ·  view source on GitHub ↗
(len: usize)

Source from the content-addressed store, hash-verified

229// utils
230
231fn gen_random_data(len: usize) -> Vec<i32> {
232 let mut data: Vec<i32> = (0..len as i32).collect();
233 common::util::shuffle(&mut data);
234 data
235}
236
237pub fn gen_asc_data(len: usize) -> Vec<i32> {
238 (0..len as i32).collect()

Callers 7

large_merge_v1Function · 0.85
large_merge_v2Function · 0.85
large_merge_v3Function · 0.85
large_quickFunction · 0.85
large_quick_3wayFunction · 0.85
large_selection_sortFunction · 0.85

Calls 1

shuffleFunction · 0.85

Tested by

no test coverage detected