c語言問題幫我程式設計序,c語言問題 幫我編乙個程式

時間 2022-06-20 02:00:04

1樓:匿名使用者

#include

main();

for(i=0;i<4;i++)

} for(i=0;i<4;i++)

high=0; //找最高平均分部分

for(i=1;i<4;i++)

if(pinjun[high]

for(i=0;i<4;i++) //列印分數部分printf("第%d個同學的平均分為%f\n",i+1,pinjun[i]);

printf("平均分最高的同學是第%d個同學平均%f分\n",high+1,pinjun[high]);}

2樓:匿名使用者

#include "stdio.h"

void main()

;for(i=0;i<4;i++)

k[i]=k[i]/5;

}max=k[i];

for(i=0;i<4;i++)

printf("max=%d\n",max);}

3樓:sshhff鳳

詳細程式**如下:

#include

#include

#include

#include

#include

#define name_length 20/*名字長度*/

#define max_student_number 4/*最大的學生數*/

/*定義乙個儲存學生資訊的結構體*/

struct student

;struct student studentdata[max_student_number];/*定義乙個陣列來儲存學生資訊*/

int studentnumber;/*用來儲存學生人數*/

/*函式宣告*/

void getstudentinformation(int studentnumber);

void getonestudentinfomation(struct student *stu);

void getmaxmarkstudentrecord(struct student stu,struct student *get);

void outputonestudentinfo(struct student out);

void menu(void);

/*主函式*/

void main()

/***************************************

函式功能:顯示選單,根據使用者選擇完成相應功能

****************************************/

void menu(void)

/***************************************

函式功能:從所有學生中,查詢平均成績最大的學生

並將查詢的結果儲存到get所指向的變數中

****************************************/

void getmaxmarkstudentrecord(struct student stu,struct student *get)

/***************************************

函式功能:顯示乙個學生的資訊

****************************************/

void outputonestudentinfo(struct student out)

4樓:匿名使用者

~~~不就是玩嘛!!~~~~這些題太簡單了,你是學程式設計的嗎???我建議你都是不要學了,你學這個沒前途....

5樓:小手涼涼地

哇,這裡分數也太好賺了吧,這樣就一百分!

大家快來搶啊,不過我不注重分數,我不搶,看別人搶!

6樓:匿名使用者

wa 好誘人啊 呵呵 不過我沒時間了 怕是要被別人強去了 555。。

7樓:匿名使用者

小kiss!這麼低階我在懷疑我的智商!

C語言程式程式設計問題 10,c語言程式程式設計

比如char c c d c的ascii的值就是 c 0 很easy吧。c語言程式程式設計 5 這個是個初學者犯的常見錯誤,意思是說在乙個專案裡定義了兩個主函式,所以報主函式重複定義了。解決辦法重新建乙個工程。沒返回值!在main函式裡加上 return 0 主函式最後加乙個return 0 試試。...

C語言程式設計問題,C語言程式設計問題 設計乙個程式,從鍵盤輸入a b c三個整數,將它們按照從大到小的次序輸出?(最

tt如果等於 a 那麼pp 0 裡的值應該 1,即 pp a a 即 pp tt a a a 0 b a 1 z a 25 明白了嗎 tt是乙個字元。也就是整數型式的ascii碼。用這個字元減掉 a 的值也就成了陣列的下標值。因為字母是按順序排列的。然後陣列下標有了,就找到那個元素值進行 操作。比如...

C語言問題,C語言程式設計問題

如果格式控制串中有非格式字元則輸入時也要輸入該非格式字元。例如 scanf d,d,d a,b,c 其中用非格式符 作間隔符,故輸入時應為 5,6,7 與scanf 雙引號之間的格式必須一樣 又如 則輸入應為 a 5,b 6,c 7 如輸入的資料與輸出的型別不一致時,雖然編譯能夠通過,但結果將不正確...