#P8741. [蓝桥杯 2021 省 B] 填空问题

[蓝桥杯 2021 省 B] 填空问题

Problem Description

This problem set contains multiple fill-in-the-blank tasks. For each task, you only need to compute the result and submit it as required.

Task A: Space

Problem Description

Xiao Lan plans to use 256MB256 \mathrm{MB} of memory to create an array. Each element of the array is a 3232-bit binary integer. If we do not consider the space used by the program itself and the extra space needed for memory management, how many 3232-bit binary integers can be stored in 256MB256 \mathrm{MB}?

Answer Submission

This is a fill-in-the-blank question. You only need to compute the result and submit it. The result of this problem is an integer. When submitting, only fill in this integer. Any extra content will make you score 00.

Task B: Cards

Problem Description

Xiao Lan has many digit cards. Each card has a digit from 00 to 99.

Xiao Lan wants to use these cards to form some numbers. He wants to start from 11 and form positive integers. Each time he forms one number, he keeps it, and the cards used for that number cannot be used to form other numbers.

Xiao Lan wants to know how far he can go starting from 11.

For example, when Xiao Lan has 3030 cards, with 33 cards for each digit from 00 to 99, he can form numbers from 11 to 1010. But when forming 1111, the digit card 11 has only one card left, which is not enough to form 1111.

Now Xiao Lan has 20212021 cards for each digit from 00 to 99, a total of 2021020210 cards. How far can he form numbers starting from 11?

Hint: It is recommended to solve this problem using computer programming.

Answer Submission

This is a fill-in-the-blank question. You only need to compute the result and submit it. The result of this problem is an integer. When submitting, only fill in this integer. Any extra content will make you score 00.

Task C: Lines

Problem Description

In a Cartesian coordinate plane, two points determine a line. If multiple points lie on the same line, then the lines determined by any two of these points are the same.

Given 2×32 \times 3 integer lattice points on the plane: $\{(x,y) \mid 0 \leq x<2,0 \leq y<3,x \in \mathbb{Z},y \in \mathbb{Z}\}$, that is, points whose xx-coordinate is an integer between 00 and 11 (including 00 and 11), and whose yy-coordinate is an integer between 00 and 22 (including 00 and 22). These points determine 1111 different lines in total.

Given 20×2120 \times 21 integer lattice points on the plane: $\{(x,y) \mid 0 \leq x<20,0 \leq y<21,x \in \mathbb{Z},y \in \mathbb{Z}\}$, that is, points whose xx-coordinate is an integer between 00 and 1919 (including 00 and 1919), and whose yy-coordinate is an integer between 00 and 2020 (including 00 and 2020). How many different lines do these points determine in total?

Answer Submission

This is a fill-in-the-blank question. You only need to compute the result and submit it. The result of this problem is an integer. When submitting, only fill in this integer. Any extra content will make you score 00.

Task D: Cargo Placement

Problem Description

Xiao Lan has a huge warehouse and can place many cargos in it.

Now Xiao Lan has nn boxes of cargo to place in the warehouse. Each box is a regular cube. Xiao Lan defines three mutually perpendicular directions: length, width, and height. The edges of each box must be strictly parallel to the length, width, and height directions.

Xiao Lan wants all the cargos to finally form a big cube. That is, stack LL, WW, and HH boxes along the length, width, and height directions respectively, satisfying n=L×W×Hn=L \times W \times H.

Given nn, how many different stacking schemes satisfy the requirement?

For example, when n=4n=4, there are the following 66 schemes: 1×1×41 \times 1 \times 4, 1×2×21 \times 2 \times 2, 1×4×11 \times 4 \times 1, 2×1×22 \times 1 \times 2, 2×2×12 \times 2 \times 1, 4×1×14 \times 1 \times 1.

When n=2021041820210418n=2021041820210418 (note that it has 1616 digits), how many schemes are there in total?

Hint: It is recommended to solve this problem using computer programming.

Answer Submission

This is a fill-in-the-blank question. You only need to compute the result and submit it. The result of this problem is an integer. When submitting, only fill in this integer. Any extra content will make you score 00.

Task E: Path

Problem Description

After learning shortest paths, Xiao Lan is very happy. He defines a special graph and wants to find the shortest path in it.

Xiao Lan's graph consists of 20212021 nodes, numbered from 11 to 20212021 in order.

For two different nodes a,ba,b, if the absolute value of the difference between aa and bb is greater than 2121, then there is no edge between them. If the absolute value of the difference between aa and bb is less than or equal to 2121, then there is an undirected edge between them, whose length is the least common multiple of aa and bb.

For example, there is no edge between node 11 and node 2323. There is an undirected edge between node 33 and node 2424 with length 2424. There is an undirected edge between node 1515 and node 2525 with length 7575.

Please compute the length of the shortest path between node 11 and node 20212021.

Hint: It is recommended to solve this problem using computer programming.

Answer Submission

This is a fill-in-the-blank question. You only need to compute the result and submit it. The result of this problem is an integer. When submitting, only fill in this integer. Any extra content will make you score 00.

Input Format

Input one uppercase letter, indicating which task it is.

Output Format

According to the input task label, output the answer for the corresponding task.

Hint

Answer template for reference.

#include<iostream>
using namespace std;
int main() {
    string ans [] = {
        "The answer of task A", // Replace inside the double quotes with the answer to task A
        "The answer of task B", // Replace inside the double quotes with the answer to task B
        "The answer of task C", // Replace inside the double quotes with the answer to task C
        "The answer of task D", // Replace inside the double quotes with the answer to task D
        "The answer of task E", // Replace inside the double quotes with the answer to task E
    };
    char T;
    cin >> T;
    cout << ans[T - 'A'] << endl;
    return 0;
}

Translated by ChatGPT 5