Codeforces Testing Round 2


A. Measuring Lengths in Baden
time limit per test: 2 seconds
memory limit per test: 256 megabytes
input: standard input
output: standard output

Examples
Input
42
Output
1 2
Input
5
Output
0 2
----------------------------------------------------------------------------------------------------
B. Simple XML
time limit per test: 2 seconds
memory limit per test: 256 megabytes
input: standard input
output: standard output

Examples
Input
<a><b><c></c></b></a>
Output
<a>
  <b>
    <c>
    </c>
  </b>
</a>
Input
<a><b></b><d><c></c></d></a>
Output
<a>
  <b>
  </b>
  <d>
    <c>
    </c>
  </d>
</a>
----------------------------------------------------------------------------------------------------
C. Hobbits' Party
time limit per test: 2 seconds
memory limit per test: 256 megabytes
input: standard input
output: standard output

Examples
Input
4
Output
3
1 2 
1 3 
2 3 
Input
5
Output
3
1 2 
1 3 
2 3 
----------------------------------------------------------------------------------------------------
D. Two progressions
time limit per test: 1 second
memory limit per test: 256 megabytes
input: standard input
output: standard output

Examples
Input
6
4 1 2 7 3 10
Output
1 2 3 
4 7 10 
Input
5
1 2 3 -2 -7
Output
1 2 3 
-2 -7 
----------------------------------------------------------------------------------------------------
E. MST Company
time limit per test: 8 seconds
memory limit per test: 256 megabytes
input: standard input
output: standard output

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