P11196 [COTS 2021] Sudoku String Transmission Novine (Not Judgable).
Background
Rebirth.
Translated from [Izborne Pripreme 2021 (Croatian IOI/CEOI Team Selection)](https://hsin.hr/pripreme2021/) D2T2. $\texttt{5s,0.5G}$.
Due to limitations of the Luogu judging system, this problem cannot be judged.
Description
**This is an interactive (communication) problem.**
You are given $N$ strings over the lowercase English alphabet.
You need to represent each string as a **valid** $9\times 9$ Sudoku; or, given the Sudoku you constructed, recover the original string.
Input Format
The first line contains two positive integers $\mathrm{type}, N$.
When $\mathrm{type}=1$, it means encryption is required. The next $N$ lines follow. On the $i$-th line, the first value is a positive integer $L_i$, which is the length of the $i$-th string; then comes the string $S_i$.
When $\mathrm{type}=2$, it means decryption is required. The next $N$ $9\times 9$ Sudokus follow, with no spaces in between.
Output Format
When $\mathrm{type}=1$, output $N$ $9\times 9$ Sudokus, with no spaces in between. You must ensure that the Sudokus you construct are valid.
When $\mathrm{type}=2$, output $N$ lines, each containing a string, representing the decrypted result.
Explanation/Hint
#### Constraints
For $100\%$ of the testdata, it is guaranteed that:
- $1\le N\le 30$;
- $\mathrm{type}\in \{1,2\}$;
- $1\le L_i\le 15$;
- the character set is lowercase letters.
| Test Point ID | $L_i\le$ | Special Property | Score |
| :--: | :--: | :--: | :--: |
| $1$ | $3$ | | $10$ |
| $2$ | $7$ | | $10$ |
| $3$ | $11$ | Yes | $4$ |
| $4$ | $11$ | | $6$ |
| $5$ | $12$ | Yes | $4$ |
| $6$ | $12$ | | $6$ |
| $7$ | $13$ | Yes | $7$ |
| $8$ | $13$ | | $8$ |
| $9$ | $14$ | Yes | $9$ |
| $10$ | $14$ | | $11$ |
| $11$ | $15$ | Yes | $12$ |
| $12$ | $15$ | | $13$ |
Special property: each character in the string is generated independently with equal probability.
Translated by ChatGPT 5