Skip to content

Commit

Permalink
Update lec6.md
Browse files Browse the repository at this point in the history
  • Loading branch information
Pease698 authored Dec 21, 2024
1 parent 39fe862 commit 9ce54f9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs/programming/24fall/lec6.md
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ printf("%d = %d = %d", a, *p, **var);

当我们写
```
int *p
int *p;
*p = 10;
```
编译器就会报错。这是因为我们这里的 p 是一个 **野指针**。
Expand Down Expand Up @@ -447,7 +447,7 @@ free(p);//记得将 p 的空间释放掉
```
Node find(Node head)
{
int p = head -> next;//从第一个存有数据的节点开始找
Node p = head -> next;//从第一个存有数据的节点开始找
while(p != NULL)//一直找到整个链表全部遍历完为止
{
if(check(p))
Expand Down

0 comments on commit 9ce54f9

Please sign in to comment.