c語言 編寫乙個輸出鍊錶的函式print

2021-07-12 04:21:17 字數 447 閱讀 8319

編寫乙個輸出鍊錶的函式print

。解:程式:

#include

#include

#define len sizeof(struct student)

struct student

int n;

struct student *creat()//建立鍊錶的函式

void print(struct student *head)//輸出鍊錶的函式

void main()

結果:1001,77

1003,88

1005,99

0,0now,these 3 records are:

1001    77.0

1003    88.0

1005    99.0

請按任意鍵繼續. . .

本文出自 「巖梟」 部落格,請務必保留此出處

C語言中的乙個鍊錶!

struct element struct element newelement char name char pwd int add struct element head,struct element ele while head next 0 head next ele return 1 st...

c 語言 乙個鍊錶的實現

include include typedef int elementtype typedef int bool define true 1 define false 0 inline bool compare int a,int b,bool flag typedef struct lnode l...

C語言 編寫乙個日曆

題目 列印乙個月份的日曆。分析 首先列印乙個月份的日曆,要設定乙個基準年,並且要知道這一年的一月一號是週幾 求得當年的一月一號是週幾 在求得當月的第一天是週幾。define crt secure no warnings 1 include include 某個月的日曆 int months 2 13...