Codeforces Round 299 (Div. 2)


A. Tavas and Nafas
time limit per test: 1 second
memory limit per test: 256 megabytes
input: standard input
output: standard output

Examples
Input
6
Output
six
Input
99
Output
ninety-nine
Input
20
Output
twenty
----------------------------------------------------------------------------------------------------
B. Tavas and SaDDas
time limit per test: 1 second
memory limit per test: 256 megabytes
input: standard input
output: standard output

Examples
Input
4
Output
1
Input
7
Output
2
Input
77
Output
6
----------------------------------------------------------------------------------------------------
C. Tavas and Karafs
time limit per test: 2 seconds
memory limit per test: 256 megabytes
input: standard input
output: standard output

Examples
Input
2 1 4
1 5 3
3 3 10
7 10 2
6 4 8
Output
4
-1
8
-1
Input
1 5 2
1 5 10
2 7 4
Output
1
2
----------------------------------------------------------------------------------------------------
D. Tavas and Malekas
time limit per test: 2 seconds
memory limit per test: 256 megabytes
input: standard input
output: standard output

Examples
Input
6 2
ioi
1 3
Output
26
Input
5 2
ioi
1 2
Output
0
----------------------------------------------------------------------------------------------------
E. Tavas and Pashmaks
time limit per test: 1 second
memory limit per test: 256 megabytes
input: standard input
output: standard output

Examples
Input
3
1 3
2 2
3 1
Output
1 2 3 
Input
3
1 2
1 1
2 1
Output
1 3 
----------------------------------------------------------------------------------------------------
