Building for the UN

Time limit3sMemory limit128 MB

Statement

The United Nations is going to construct a new headquarters shaped like a rectangular box. The building is made of several identical rectangular floors stacked one on top of another. Every floor is a rectangular grid of the same size, and every cell of the grid is one office.

Two offices are adjacent when they lie on the same floor and share a wall, or when one sits directly on top of the other (the ceiling of the lower office is the floor of the upper one).

The building must host $n$ national missions. Each country receives a set of offices, and the offices belonging to one country must form a connected region: from any office of a country you can reach every other office of the same country by stepping between adjacent offices of that country.

Because any two countries may want to negotiate privately behind a shared wall or ceiling, every pair of countries must own at least one pair of adjacent offices.

Such a building always exists. So that the answer is unique, you must output the specific valid building described in the Output section.

Input

A single line with one integer $n$ ($1 \le n \le 50$) — the number of countries.

Output

Construct the building exactly as follows, then print it.

  • The building has height $2$ (two floors), and each floor is an $n \times n$ grid: $n$ rows, each of $n$ characters.
  • Label the countries with the first $n$ characters of the sequence $A, B, \dots, Z, a, b, \dots, z$ (all uppercase letters first, then all lowercase letters). Call these labels $c_1, c_2, \dots, c_n$.
  • Lower floor: every office in row $i$ belongs to country $i$, so row $i$ is the character $c_i$ repeated $n$ times.
  • Upper floor: every office in column $j$ belongs to country $j$, so every row equals $c_1 c_2 \dots c_n$.

First print three integers $h$, $w$, and $l$ — the height, width, and length of the building; here $h = 2$ and $w = l = n$. Then print the lower floor as $n$ lines of $n$ characters, print one empty line, and print the upper floor as $n$ lines of $n$ characters.