File tree Expand file tree Collapse file tree 1 file changed +13
-2
lines changed Expand file tree Collapse file tree 1 file changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -24,8 +24,19 @@ Run `cargo build --release` before benchmarking after you make a change!
2424
2525## Sorting numbers
2626
27- - Generate a list of numbers: ` seq 0 100000 | sort -R > shuffled_numbers.txt ` .
28- - Benchmark numeric sorting with hyperfine: ` hyperfine "target/release/coreutils sort shuffled_numbers.txt -n -o output.txt" ` .
27+ - Generate a list of numbers:
28+ ```
29+ shuf -i 1-1000000 -n 1000000 > shuffled_numbers.txt
30+ # or
31+ seq 1 1000000 | sort -R > shuffled_numbers.txt
32+ ```
33+ - Benchmark numeric sorting with hyperfine
34+ ```
35+ hyperfine --warmup 3 \
36+ '/tmp/gnu-sort -n /tmp/shuffled_numbers.txt'
37+ '/tmp/uu_before sort -n /tmp/shuffled_numbers.txt'
38+ '/tmp/uu_after sort -n /tmp/shuffled_numbers.txt'
39+ ```
2940
3041## Sorting numbers with -g
3142
You can’t perform that action at this time.
0 commit comments