c语言出错

[复制链接]
查看11 | 回复1 | 2008-12-29 21:18:27 | 显示全部楼层 |阅读模式
#include
#include
#define N 5
main(){
int i;
float he(float *,int);
float hexy(float *,float *,int);
float hexsq(float *,int);
float p[N],t[N],T[N],x[N],y[N],a,b;
printf("顺序为x y,之间以空格隔开\n");
for (i=0;i #include#define N 5 float he(float H[],int n){float sum=0;int i;for (i=0;i<n;i++){ sum+=H;}return sum; } float hexy(float H[],float L[],int n){float sum=0;int i;for (i=0;i<n;i++){ sum+=H*L;}return sum; } float hexsq...
回复

使用道具 举报

千问 | 2008-12-29 21:18:27 | 显示全部楼层
函数声明放在main()函数前面,好像C语言不支持在函数内部声明函数。...
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行