The King`s Ups and Downs#5128

The King`s Ups and Downs

1 second
32 megabytes
Hard

The king has guards of all different heights. Rather than line them up in increasing or decreasing height order, he wants to line them up so each guard is either shorter than the guards next to him or taller than the guards next to him (so the heights go up and down along the line). For example, seven guards of heights , , , , , and cm. could be arranged as:

or perhaps:

The king wants to know how many guards he needs so he can have a different up and down order at each changing of the guard for rest of his reign. To be able to do this, he needs to know for a given number of guards, , how many different up and down orders there are:

For example, if there are four guards: , , , can be arranged as:

, , , , , , , , ,

For this problem, you will write a program that takes as input a positive integer , the number of guards and returns the number of up and down orders for guards of differing heights.

Input

The first line of input contains a single integer , (1 \leq P \leq 1000), which is the number of data sets that follow Each data set consists of a single line of input containing two integers. The first integer, is the data set number. The second integer, (1 \leq n \leq 20), is the number of guards of differing heights.

Output

For each data set there is one line of output. It contains the data set number () followed by a single space, followed by the number of up and down orders for the guards.

Examples

Example 1

Loading
Loading