Sync zh and zh-hant versions (#1801)

* Sync zh and zh-hant versions.

* Unifying "数据体量" -> "数据规模".
This commit is contained in:
Yudong Jin
2025-08-28 04:51:02 +08:00
committed by GitHub
parent 803c0e09c7
commit 7b320e14fe
12 changed files with 48 additions and 54 deletions

View File

@ -13,22 +13,12 @@ fn test_push_max(heap: &mut BinaryHeap<i32>, val: i32) {
println!("\n元素 {} 入堆積後", val);
print_util::print_heap(heap.iter().map(|&val| val).collect());
}
fn test_push_min(heap: &mut BinaryHeap<Reverse<i32>>, val: i32) {
heap.push(Reverse(val)); // 元素入堆積
println!("\n元素 {} 入堆積後", val);
print_util::print_heap(heap.iter().map(|&val| val.0).collect());
}
fn test_pop_max(heap: &mut BinaryHeap<i32>) {
let val = heap.pop().unwrap();
println!("\n堆積頂元素 {} 出堆積後", val);
print_util::print_heap(heap.iter().map(|&val| val).collect());
}
fn test_pop_min(heap: &mut BinaryHeap<Reverse<i32>>) {
let val = heap.pop().unwrap().0;
println!("\n堆積頂元素 {} 出堆積後", val);
print_util::print_heap(heap.iter().map(|&val| val.0).collect());
}
/* Driver Code */
fn main() {