
c语言
「已注销」
这个作者很懒,什么都没留下…
展开
-
转载gets()和scanf puts和printf
转载出处http://blog.youkuaiyun.com/xingjiarong/article/details/47282817一、scanf()和gets()1.scanf()所在头文件:stdio.h语法:scanf(“格式控制字符串”,变量地址列表);接受字符串时:scanf(“%s”,字符数组名或指针);2.gets()所在头文件:stdio.h语法:gets(字符数组名或指针)...转载 2020-04-30 10:25:02 · 279 阅读 · 0 评论 -
缓冲区
原文链接:https://blog.youkuaiyun.com/u013162035/article/details/78620842问题描述一:(分析scanf()和getchar()读取字符)scanf(), getchar()等都是标准输入函数,一般人都会觉得这几个函数非常简单,没什么特殊的。但是有时候却就是因为使用这些函数除了问题,却找不出其中的原因。下面先看一个很简单的程序:程序1:int...转载 2020-04-24 10:26:34 · 226 阅读 · 0 评论 -
链栈相关操作及实现
#include <iostream>using namespace std;typedef struct Stacknode{ int data; struct Stacknode *next;}Stacknode ,*LinkStackPtr;typedef struct LinkStack{ LinkStackPtr top; in...原创 2020-04-14 16:12:23 · 163 阅读 · 0 评论 -
链表
#include <stdio.h>#include <stdlib.h>typedef struct Node{ int data; struct Node *next;}Node;typedef struct Node *LinkList;void CreateListEnd(LinkList *head);void PrintList...原创 2020-04-09 17:38:13 · 191 阅读 · 0 评论 -
c链表
温凯老师数据结构#include <stdio.h>#include <stdlib.h>typedef struct _node{ int data; struct _node *next;}Node;typedef struct _list{ Node *head;}List;void InsertList(List *li...原创 2020-03-18 07:22:31 · 239 阅读 · 0 评论 -
链表
郝斌数据结构//郝斌数据结构#include <stdio.h>#include <stdlib.h>#include <stdbool.h>typedef struct Node{ int data; //数据域 struct Node *pNext; //指针域} NODE, *PNODE; ...原创 2020-03-18 07:21:18 · 136 阅读 · 0 评论 -
常量和指针总结
const 关键字1.在const 关键字的修饰下,变量就会失去可修改的特性,变成只读的属性.const int num = 4;num = 3; //试图修改常量的行为将会导致程序出错.2.指向常量的指针指针可以指向被const修饰过的变量int num = 520;const int cnum = 880;const int *pc = &cnum;//尝试修改指...原创 2020-03-17 08:48:15 · 130 阅读 · 0 评论