|
马上注册,结交更多好友,享用更多功能^_^
您需要 登录 才可以下载或查看,没有账号?立即注册
x
显示的是- --------------------Configuration: one - Win32 Debug--------------------
- Compiling...
- one.c
- D:\C语言\MSDev98\MyProjects\one\one.c(12) : error C2065: 'FebSold' : undeclared identifier
- D:\C语言\MSDev98\MyProjects\one\one.c(12) : error C2065: 'MarSold' : undeclared identifier
- 执行 cl.exe 时出错.
- one.obj - 1 error(s), 0 warning(s)
复制代码
代码是:
- #include <stdio.h>
- int main(void)
- {
- const float Revenue_Per_150 = 4.5f;
- short JanSold = 23500; // Stock sold in January
- short FebSlod = 19300; // Stock sold in February
- short MarSlod = 21600; // Stock sold in March
- float RevQuarter = 0.0f; // Sales for the quarter
- short QuarterSold = JanSold + FebSold + MarSold; // Calculate quarterly total
- // Output minthly sales and total for the quarter
- printf("Stock sold in\nJan:%d\nFeb:%d\n",JanSold,FebSold,MarSold);
- printf("Total stock sold in first quarter:%d\n",QuarterSold);
-
- // Calculate the total recenue for the quarter and output it
- printf("Sales recenue this quarter is:$%.2f\n",RevQuarter);
- return 0;
- }
复制代码
希望的得到求解,谢谢 |
|