Codeforces Beta Round 12 (Div 2 Only)


A. Super Agent
time limit per test: 2 seconds
memory limit per test: 256 megabytes
input: standard input
output: standard output

Examples
Input
XX.
...
.XX
Output
YES
Input
X.X
X..
...
Output
NO
----------------------------------------------------------------------------------------------------
B. Correct Solution?
time limit per test: 2 seconds
memory limit per test: 256 megabytes
input: standard input
output: standard output

Examples
Input
3310
1033
Output
OK
Input
4
5
Output
WRONG_ANSWER
----------------------------------------------------------------------------------------------------
C. Fruits
time limit per test: 1 second
memory limit per test: 256 megabytes
input: standard input
output: standard output

Examples
Input
5 3
4 2 1 10 5
apple
orange
mango
Output
7 19
Input
6 5
3 5 1 6 8 1
peach
grapefruit
banana
orange
orange
Output
11 30
----------------------------------------------------------------------------------------------------
D. Ball
time limit per test: 2 seconds
memory limit per test: 256 megabytes
input: standard input
output: standard output

Examples
Input
3
1 4 2
4 3 2
2 5 3
Output
1
----------------------------------------------------------------------------------------------------
E. Start of the season
time limit per test: 2 seconds
memory limit per test: 256 megabytes
input: standard input
output: standard output

Examples
Input
2
Output
0 1
1 0
Input
4
Output
0 1 3 2
1 0 2 3
3 2 0 1
2 3 1 0
----------------------------------------------------------------------------------------------------
