mirror of
https://github.com/krahets/hello-algo.git
synced 2025-12-19 07:17:54 +08:00
Add C++ code for the chapter binary tree.
This commit is contained in:
@@ -40,7 +40,7 @@ int main() {
|
||||
cout << "目标元素 3 的索引 = " << index << endl;
|
||||
|
||||
/* 哈希查找(链表) */
|
||||
ListNode* head = vectorToLinkedList(nums);
|
||||
ListNode* head = vecToLinkedList(nums);
|
||||
// 初始化哈希表
|
||||
unordered_map<int, ListNode*> map1;
|
||||
while (head != nullptr) {
|
||||
|
||||
Reference in New Issue
Block a user