# Time

Time

Digital clock use 4 digits to express time, each digit is described by 3*3 characters (including”|”,”_”and” “).now given the current time, please tell us how can it be expressed by the digital clock.

There are several test cases.

Each case contains 4 integers in a line, separated by space.

Proceed to the end of file.

For each test case, output the time expressed by the digital clock such as Sample Output.

``````1 2 5 6
2 3 4 2``````

``````    _  _  _
| _||_ |_
||_  _||_|
_  _     _
_| _||_| _|
|_  _|  ||_
``````

``````#include <stdio.h>

int t[10][3][3]=

{

//0

{

{' ', '_', ' '},

{'|', ' ', '|'},

{'|', '_', '|'}

},

//1

{

{' ', ' ', ' '},

{' ', ' ', '|'},

{' ', ' ', '|'},

},

//2

{

{' ','_',' '},

{' ','_','|'},

{'|','_',' '},

},

//3

{

{' ','_',' '},

{' ','_','|'},

{' ','_','|'},

},

//4

{

{' ',' ',' '},

{'|','_','|'},

{' ',' ','|'},

},

//5

{

{' ','_',' '},

{'|','_',' '},

{' ','_','|'},

},

//6

{

{' ','_',' '},

{'|','_',' '},

{'|','_','|'},

},

//7

{

{' ','_',' '},

{' ',' ','|'},

{' ',' ','|'},

},

//8

{

{' ','_',' '},

{'|','_','|'},

{'|','_','|'},

},

//9

{

{' ','_',' '},

{'|','_','|'},

{' ','_','|'},

},

};

int main()

{

//freopen("in.in","r",stdin);

//freopen("out.out","w",stdout);

int a[4];

int i,j,k;

while(scanf("%d %d %d %d",&a[0], &a[1],&a[2],&a[3]) != EOF)

{

for(i=0; i<3; ++i)

{

for(j=0; j<4; ++j)

{

for(k=0;k<3; ++k)

{

printf("%c", t[a[j]][i][k]);

}

}

printf("\n");

}

}

}

``````

``````//1004
#include <iostream>
#include <string>
#include <map>
#include <cmath>
#include <stdio.h>
#define N 1010

using namespace std;

int a, b, c;
int n;
string arr_b[N];

int main()
{
while (scanf("%d %d %d", &a, &b, &c)==3)
{
map<string, int> hasha;
for (int i = 0; i < a; i++)
{
string sa;
cin >> sa;
hasha[sa] = 1;
}

for (int i = 0; i < b; i++)
cin >> arr_b[i];

map<string, int> hashc;
for (int i = 0; i < c; i++)
{
string sc;
cin >> sc;
hashc[sc] = 1;
}

int first = 1;
for (int i = 0; i < b; i++)
{
if (hasha[arr_b[i]]==1 && hashc[arr_b[i]]==0)
{
if (!first)
cout << ' ';
else
first = 0;
cout << arr_b[i];
}
}

if (!first)
cout << endl;
else
cout << "No enemy spy" << endl;
}

return 0;
}

``````