原创 循環隊列

#include <stdio.h> #include <stdlib.h> #define MAX 6 typedef struct { int *data; int rear; //尾“指針”,指向隊列尾元素的下一個位置 i

原创 數據結構——順序表的創建及功能函數

//SqList.h #ifndef _SQ_LIST_ #define _SQ_LIST_ #define MAX 100 typedef struct _LinerList { int data[MAX]; int lengt

原创 標準頭文件結構

標準頭文件結構的格式:

原创 多項式的加法實現

//多項式的加法實現 #include <stdio.h> #include <stdlib.h> typedef struct _poly { int coef; int expo; struct _poly *next; }P

原创 循環鏈表

#ifndef _Node_ #define _Node_ typedef struct _node { int number; struct _node *next; }Node; #endif // ! _node_#i

原创 Cadence_OrCAD篇 學習筆記

1.    Library裏點擊New part自建元件, 從上到下依次爲: 元件名,代替使用稱號,封裝 2.    勾選掉preference裏的pointer snap to grid 可以讓線的起點和終點從任意位置開始 3.   

原创 輸入年月日,計算該年第幾天

#include<stdio.h> struct date{ int day; int month; int year; }; struct date *Time(struct date *Time){ scanf("%d %

原创 c++歌詞生成器

1. 要求:    有原始歌詞文件“xxx.lrc”,通過編寫程序生成新的文件“完整歌詞.txt”,內容應與正常播放順序一致。2. 代碼:#include <stdio.h> #include <stdlib.h> #includ

原创 行指針與列指針_2

行指針,顧名思義就是指向一行的指針。那麼哪裏會用到行指針呢,用的最多的,那就是二維指針了,大家都知道,我們通常把二維指針看成一個行列式,但是它在內存中的排序卻是和一維指針一樣的。   比如組a[2][3]={{1,2,3}{4,5,6

原创 行指針與列指針_1

指針與多維數組 (主要指二維數組) int a[3][4]={1,3,5,7,9,11,13,15,17,19,21,23};   換個角度看世界: 如首行一樣,將首行視爲一個元素,一個特殊的元素,這個“特殊的”元素是一個一維數組。那麼

原创 二叉樹創建及功能函數

#ifndef _BI_NODE_ #define _BI_NODE_ typedef struct _binode { char data; struct _binode *lchild, *rchild; }BiNode; #

原创 #include與頭文件

原创 c語言枚舉類型

在實際應用中,有的變量只有幾種可能取值。如人的性別只有兩種可能取值,星期只有七種可能取值。在程序中,我們可以利用預處理指令#define來完成這項工作,如: #define MON  1 #define TUE   2 #define

原创 輸入年和第幾天算日期

#include "stdio.h" typedef struct{ int day; int year; }indate; typedef struct{ int day; int month; int year; }op