Focusing
The world is uncertain, we are both dark horses; As soon as the alarm goes off, we are both oxen and horses.
-
Institute of Computing Technology, CAS
- Beijing, China
-
15:32
(UTC +08:00) - https://github.com/ggssh
Highlights
Pinned Loading
-
Monkey Sort
Monkey Sort 1fn monkey_sort<T: Ord>(arr: &mut [T]) {
2while !is_sorted(arr) {
3arr.shuffle(&mut rand::thread_rng());
4}
5}
-
Sleep Sort
Sleep Sort 1fn sleep_sort(arr: &mut [u64]) {
2let (s, r) = std::sync::mpsc::channel();
3for &n in arr {
4let s = s.clone();
5std::thread::spawn(move || {
Something went wrong, please refresh the page to try again.
If the problem persists, check the GitHub status page or contact support.
If the problem persists, check the GitHub status page or contact support.