码迷,mamicode.com
首页 > 编程语言 > 详细

NBUT 1219 Time(三维数组)

时间:2015-08-18 11:55:59      阅读:120      评论:0      收藏:0      [点我收藏+]

标签:nbut   水题   

题目链接:https://ac.2333.moe/Problem/view.xhtml?id=1219

#include<iostream>
#include<cstdio>
using namespace std;
char numb[11][3][3]= {{{' ','_',' '},{'|',' ','|'},{'|','_','|'}},
    {{' ',' ',' '},{' ',' ','|'},{' ',' ','|'}},
    {{' ','_',' '},{' ','_','|'},{'|','_',' '}},
    {{' ','_',' '},{' ','_','|'},{' ','_','|'}},
    {{' ',' ',' '},{'|','_','|'},{' ',' ','|'}},
    {{' ','_',' '},{'|','_',' '},{' ','_','|'}},
    {{' ','_',' '},{'|','_',' '},{'|','_','|'}},
    {{' ','_',' '},{' ',' ','|'},{' ',' ','|'}},
    {{' ','_',' '},{'|','_','|'},{'|','_','|'}},
    {{' ','_',' '},{'|','_','|'},{' ','_','|'}}
};
int main()
{
    int a,b,c,d;
    while(scanf("%d %d %d %d",&a,&b,&c,&d)==4)
    {
        for(int i=0; i<3; i++)
        {
            for(int j=0; j<3; j++)
            {
                cout<<numb[a][i][j];
            }
            for(int j=0; j<3; j++)
            {
                cout<<numb[b][i][j];
            }
            for(int j=0; j<3; j++)
            {
                cout<<numb[c][i][j];
            }
            for(int j=0; j<3; j++)
            {
                cout<<numb[d][i][j];
            }
            cout<<endl;
        }
    }
    return 0;
}


版权声明:本文为博主原创文章,未经博主允许不得转载。

NBUT 1219 Time(三维数组)

标签:nbut   水题   

原文地址:http://blog.csdn.net/qq_30076791/article/details/47749061

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!