c++问题求高手

[复制链接]
查看11 | 回复3 | 2011-9-29 13:39:36 | 显示全部楼层 |阅读模式
#includeusing namespace std;int main(){ const int d=7;
const int l=5;
int u[d][l];
//定义一个二维的整型数组u[7][5]
int day,lab,t,average; //给二维数组元素赋值
for(day=0;day<d;day++) //行扫描
{
cout<<(day+1)<<endl;
for(lab=0;lab<l;lab++) //列扫描
{
cout<<"lab number ...
回复

使用道具 举报

千问 | 2011-9-29 13:39:36 | 显示全部楼层
#includeusing namespace std;int main() {
const int d = 7;
const int l = 5;
int u[d][l];
int day,lab,t;double average;
for(day = 0;day < ...
回复

使用道具 举报

千问 | 2011-9-29 13:39:36 | 显示全部楼层
二维数组,计算每一列的平均值如下:1 2 3 4 51 2 3 4 51 2 34 5就是分别计算割裂的平均值...
回复

使用道具 举报

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

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行