随笔分类 -  链表

摘要:主要函数 1: malloc:函数原型 void *malloc(unsigned int size); 分配一个长度为size的连续空间,返回首地址。 空间不足时返回HULL; 2: calloc:函数原型 void *calloc(unsigned n,unsigned size) 分配n个长度 阅读全文
posted @ 2022-04-25 16:09 xxj112 阅读(50) 评论(0) 推荐(0)
摘要:#include <stdio.h> #include <malloc.h> struct node { int date; struct node *next; }; int main() { struct node a,b,c,*head,*p; a.date=1; b.date=2; c.da 阅读全文
posted @ 2022-04-24 21:51 xxj112 阅读(27) 评论(0) 推荐(0)
摘要:#include<bits/stdc++.h> using namespace std;typedef long long ll;#define INF 0x3f3f3f3fconst ll N=610000;ll vis[21900]; //相当于bool函数ll dis[21900],u[N], 阅读全文
posted @ 2022-04-20 18:08 xxj112 阅读(61) 评论(0) 推荐(0)