正在加载图片...
4.include<stdio.h int WF(int x,int y)( X=x十y; y十=x; return x+y; void main(){ int x=3,y=8; printf("%d\n",WF(x,y)); } 5.include<stdio.h> int LA(int a,int n){ int i,s=0; for(i=0;i<n;i++)s+=ai]; return s; } void main(){ inta[5]={1,2,3,4,5}; int b=LA(a,5)+LA(a+2,3); printf("b=%d\n",b); 得分 评卷人 四、写出下列每个函数的功能(每小题6分,共12分) 1.int WC(int a],int n,int k){ int i,c=0; for(i=0;i<n;i++) if(a[i]>=k)c++; return c; 函数功能: 1375int n) { 4. 5. # include<stdio. h> int WF(int x , int y) { x=x 十y; Y+=X; return 十y; void main() { int x=3 , y=8; printf("%d\n" ,WF(x ,y»; # include<stdio. h> int LA(int int i,s=O; for(i=O; i<n; == a[i]; return s; void main() { int a[5]={1 ,2,3,4,5}; int b=LA(a,5)+LA(a十2 ,3); printf("b=%d\ntl , b) ; 得分|评卷人 四、写出下列每个函数的功能(每小题 1. int WC(int int n , int k) { int i, c=O; for(i=O; i<n; if(a[i]>=k) return c; 函数功能: 1375
<<向上翻页向下翻页>>
©2008-现在 cucdc.com 高等教育资讯网 版权所有