[SOLVED] UVa online 101 The Blocks Problem – WA

If you’re getting WA (Wrong Answer) for the problem 101 – The Blocks Problem. It means you need to have one more newline at the end of the output.

Wrong:
=======================
0:
1: 1
2: 2
3: 3
4:
5: 5 22 0
6: 6 14 13
7: 7
8:
9:
10: 10 15 12 4
11: 11
12:
13:
14:
15:
16:
17: 17
18: 18
19: 19
20: 20 8
21: 21 9 16
22:
23: 23
=======================
Right:
=======================
0:
1: 1
2: 2
3: 3
4:
5: 5 22 0
6: 6 14 13
7: 7
8:
9:
10: 10 15 12 4
11: 11
12:
13:
14:
15:
16:
17: 17
18: 18
19: 19
20: 20 8
21: 21 9 16
22:
23: 23

=======================

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s