- 博客(4)
- 收藏
- 关注
原创 简单的图书馆管理系统
#include<stdio.h> #include<string.h> #include<stdlib.h> struct library { int num; char name[20] ; char author[20] ; struct librarynext; };//定义结构体 int main() { int n,c=0,l,flag; char s[20]; struct library head,p,q;/定义指针/ head=(struct libra
2021-03-07 13:16:52 355
原创 双链表的头插法的输入和输出(头插法的输出是反序的如 输入4 5 6 7,输出7 6 5 4 )
#include using namespace std; typedef struct dian { int data; struct dian *next; struct dian *prior; }Dlink;//////////////////////开辟双链表的类型 void jianli(Dlink *&L,int a[],int n) 建立双链表 { Dlink *s; int i; L=new Dlink; L->next=NULL; L->prior=NULL; f
2020-10-11 10:31:36 135
原创 2020-10-11
#include<stdio.h> #include<malloc.h> typedef struct LNode { int data; struct LNode next; }Linklist; void kaishi(Linklist * &L,int a[],int n) { Linklist s; L=(Linklist)malloc(sizeof(Linklist)); L->next=NULL; for(int i=0;i<n;i++) { s=(L
2020-10-11 09:58:14 102
原创 单链表的建立
单链表的建立 #include<stdio.h> #include<malloc.h> typedef struct LNode { int data; struct LNode next; }Linklist; void kaishi(Linklist * &L,int a[],int n) { Linklist s; L=(Linklist)malloc(sizeof(Linklist)); L->next=NULL; for(int i=0;i<n;i++)
2020-10-04 16:46:59 103
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人