P8713 [Lanqiao Cup 2020 NOI Qualifier A2] Fill-in-the-Blank Problems
Description
## Task A: Making House Numbers
### [Problem Description]
Xiao Lan wants to make house number plates for the residents of a street.
There are $2020$ households on this street, and the house numbers are numbered from $1$ to $2020$.
Xiao Lan’s method is to first make the digit characters $0$ to $9$, and then paste the needed characters onto each plate. For example, for house number $1017$, the characters `1`, `0`, `1`, `7` need to be pasted in order. That is, it needs $1$ character `0`, $2$ characters `1`, and $1$ character `7`.
Question: To make all house number plates from $1$ to $2020$, how many digit characters `2` are needed in total?
### [Answer Submission]
This is a fill-in-the-blank question. You only need to compute the result and submit it. The result is an integer. When submitting, only fill in this integer; any extra content will not be scored.
## Task B: Reduced Fractions
### [Problem Description]
If the greatest common divisor of the numerator and denominator of a fraction is $1$, then this fraction is called a reduced fraction.
For example, $\frac{3}{4},\frac{5}{2},\frac{1}{8},\frac{7}{1}$ are all reduced fractions.
Question: How many reduced fractions are there such that both the numerator and denominator are integers between $1$ and $2020$ (including $1$ and $2020$)?
### [Answer Submission]
This is a fill-in-the-blank question. You only need to compute the result and submit it. The result is an integer. When submitting, only fill in this integer; any extra content will not be scored.
## Task C: Snake-like Filling
### [Problem Description]
As shown in the figure below, Xiao Ming fills an infinite matrix in a “snake-like” pattern with positive integers starting from $1$.
$\begin{array}{cccccc}1 & 2 & 6 & 7 & 15 & \ldots \\ 3 & 5 & 8 & 14 & \ldots & \\ 4 & 9 & 13 & \ldots & & \\ 10 & 12 & \ldots & & & \\ 11 & \ldots & & & & \\ \ldots & & & & & \end{array}$
It is easy to see that the number in the second row and second column is $5$. Please calculate what the number in the $20$-th row and $20$-th column is.
### [Answer Submission]
This is a fill-in-the-blank question. You only need to compute the result and submit it. The result is an integer. When submitting, only fill in this integer; any extra content will not be scored.
## Task D: Seven-segment Display
### [Problem Description]
Xiao Lan wants to use a seven-segment display to represent a special kind of characters.

The figure above shows a diagram of a seven-segment display. There are $7$ light-emitting diodes in the display, labeled $a,b,c,d,e,f,g$.
Xiao Lan wants to choose a subset of diodes (at least one) to light up to represent a character. When designing a character, all lit diodes must be connected as one single piece.
For example, lighting $\mathrm{b}$ only, with all other diodes off, can represent a character.
For example, lighting $\mathrm{c}$ only, with all other diodes off, can represent a character. This scheme can represent a different character from the one in the previous line, even though they look similar.
For example, lighting $a,b,c,d,e$ and turning off $f,g$ can represent a character.
For example, lighting $b,f$ only, with all other diodes off, cannot represent a character, because the lit diodes are not connected as one piece.
Question: How many different characters can Xiao Lan represent using the seven-segment display?
### [Answer Submission]
This is a fill-in-the-blank question. You only need to compute the result and submit it. The result is an integer. When submitting, only fill in this integer; any extra content will not be scored.
## Task E: Plane Division
### [Problem Description]
What is the maximum number of regions the plane can be divided into by $20$ circles and $20$ straight lines?
### [Answer Submission]
This is a fill-in-the-blank question. You only need to compute the result and submit it. The result is an integer. When submitting, only fill in this integer; any extra content will not be scored.
Input Format
Input a capital letter, indicating which task it is.
Output Format
Output the answer corresponding to the given task letter.
Explanation/Hint
An answer template is provided for reference.
```cpp
#include
using namespace std;
int main() {
string ans [] = {
"The answer of task A", // Replace the content in double quotes with the answer for task A
"The answer of task B", // Replace the content in double quotes with the answer for task B
"The answer of task C", // Replace the content in double quotes with the answer for task C
"The answer of task D", // Replace the content in double quotes with the answer for task D
"The answer of task E", // Replace the content in double quotes with the answer for task E
};
char T;
cin >> T;
cout