From 4f7a07025a07889a4218e528127dfdf74e9dc522 Mon Sep 17 00:00:00 2001 From: LHY20 <3364451258@qq.com> Date: Sun, 20 Jul 2025 22:31:52 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0VS=20Code=20C++=E5=BC=80?= =?UTF-8?q?=E5=8F=91=E9=85=8D=E7=BD=AE=E6=96=87=E4=BB=B6=EF=BC=8C=E5=8C=85?= =?UTF-8?q?=E6=8B=ACc=5Fcpp=5Fproperties.json=E3=80=81launch.json=E3=80=81?= =?UTF-8?q?settings.json=E5=92=8Ctasks.json?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- 翁凯C语言/13/链表的搜索.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/翁凯C语言/13/链表的搜索.c b/翁凯C语言/13/链表的搜索.c index 9776cf0..f16c879 100644 --- a/翁凯C语言/13/链表的搜索.c +++ b/翁凯C语言/13/链表的搜索.c @@ -46,6 +46,16 @@ void add(List* pList, int value) } } +void print(List* pList) +{ + Node *p; + for (p=pList->head; p; p=p->next) + { + printf("%d\t", p->value); + } + printf("\n"); +} + int main() { // 设置控制台编码为UTF-8 @@ -69,6 +79,7 @@ int main() } } while (number!=-1); + print(&list); return 0; } \ No newline at end of file