刚学不会,请各位大侠看看...
#include<stdio.h>
#define Height 10
int calculate(int Long,int Width);
int main()
{
int m_Long;
int m_Width;
int result;
printf("ÕâÊdz¤·½Ðεĸß\n");
printf("%d\n",Height);
printf("ÇëÊäÈ볤·½Ðεij¤\n");
scanf("%d",&m_Long);
printf("ÇëÊäÈ볤·½ÐεĿí\n");
scanf("%d",&m_Width);
result=calculate(m_Long,m_Width);
printf("%d\n",result);
return 0;
}
int calculate(int Long,int Width)
{
int calculate=Long*Width*Height;
return result;
}
这个是按照书上搬过来的,结果运行说result结果没定义,程序中乱码的是一些中文提示,刚学不会请各位大侠看看....