C++ 重写《算法(第4版)》1.3 节的代码以及该节习题解答

本文汇总了笔者用 C++ 重写《算法(第4版)》 1.3 节的代码和该节习题解答的链接。

正文

涉及的算法、数据类型和测试用例。

算法、数据类型和测试用例 重写代码所在文件 说明
ArrayIterator array_iterator.hxx 数组迭代器类
Bag bag.hxx 背包类
Evaluate evaluate.cpp Dijstra 的双栈算术表达式求值算法
FixedCapacityStack fixed_capacity_stack.hxx 定容栈类
FixedCapacityStackOfStrings fixed_capacity_stack_of_strings.hxx 定容字符串栈类
Iterable iterable.hxx 可迭代接口
Iterator iterator.hxx 迭代器接口
ListIterator list_iterator.hxx 链表迭代器类
Node node.hxx 链表类
Queue queue.hxx 先进先出队列类
Reverse reverse.cpp Stack 的用例
readInts() read_ints.cpp Queue 的用例
Stack stack.hxx 下压栈类
Stats stats.cpp Bag 的用例
ResizingArrayStack resizing_array_stack.hxx 动态调整数组大小的下压栈类
ReverseArrayIterator reverse_array_iterator.hxx 动态调整数组大小的下压栈的迭代器类
- test_fixed_capacity_stack.cpp FixedCapacityStack 的用例
- test_fixed_capacity_stack_of_strings.cpp FixedCapacityStackOfStrings 的用例
- test_queue.cpp Queue 的用例
- test_resizing_array_stack.cpp ResizingArrayStack 的用例
- test_stack.cpp Stack 的用例

习题

含习题、提高题和实验题。

* * * * * * * * * *
1.ans 2.ans 3.ans
3.cpp
4.cpp
4.txt
5.cpp 6.ans 7.ans 8.ans
8.cpp
8.txt
9.cpp 10.cpp
10.txt
11.cpp
11.txt
12.cpp 13.ans
13.cpp
14.cpp
resizing_array_queue.hxx
15.cpp
15.txt
16.cpp
16.txt
17.cpp
17.txt
18.ans 19.cpp 20.cpp
21.cpp 22.ans 23.ans 24.cpp 25.cpp 26.cpp 27.cpp 28.cpp
ring_queue.hxx
29.cpp 30.cpp
31.cpp
biway_node.hxx
32.cpp
steque.hxx
33.cpp
deque.hxx
biway_iterator.hxx
biway_list_iterator.hxx
resizing_array_deque.hxx
34.cpp
random_bag.hxx
35.cpp
random_queue.hxx
36.cpp 37.cpp 38.cpp
generalized_queue.hxx
resizing_array_generalized_queue.hxx
39.cpp
ring_buffer.hxx
40.cpp
40.txt
41.cpp 42.ans 43.cpp 44.cpp
buffer.hxx
45.cpp 46.ans 47.cpp 48.cpp
deque_stacks.hxx
49.cpp
stacks_queue.hxx
50.cpp
fast_fail_list_iterator.hxx
fast_fail_stack.hxx
posted @ 2026-05-26 16:50  green-cnblogs  阅读(8)  评论(0)    收藏  举报