⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 nizhi.c

📁 数据结构基础学习程序
💻 C
字号:
#include<stdio.h>           //ni zhi hao shi le -zjd-zuihaode
#include<malloc.h>
void main()
{
 struct node           //dingyi jiedianleixing 
 {
 char data;
 struct node *next;
 }*head,*p;
 char ch;
 head=NULL;
 printf("please input you serial end with enter:\n");
 while((ch=getchar()) && (ch!='\n'))
 {
 p=malloc(sizeof(struct node));//xinjian jiedian p
 p->data=ch;
 p->next=head;
 head=p;//weicha fa jianbiao 
 }
 printf("now show th serial after change:\n");
 while(head)
 {
  p=head;
  head=head->next;
  printf("%c",p->data);
  // putchar(p->data);//shuchu
  free(p);
  }
  }

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -