Build More Roads!
The king of Talkland is planning to build new roads in the kingdom. Indeed, the old roads are all muddy and full of ruts. The new roads will be paved with yellow bricks and shine on the sun. Of course, all roads will be two-way.
There are n cities in Talkland and the king wants to build as many roads as possible. However, he knows that if there are r cities, such that each pair of them is connected by a road, citizens of those communicate too much, so the risk of the revolution becomes too strong. Therefore he wants to build as many roads as possible, but in such way that no r cities are all pairwise connected.
You, his transportation and educaction wizard, must help!
Input
Input file contains n and r (3 ≤ n ≤ 100, 3 ≤ r ≤ n).
Output
On the first line of the output file output m — the number of roads to build. Next m lines must contain the descriptions of the roads, for each road output the cities it must connect.