Deltix Round, Autumn 2021 (open for everyone, rated, Div. 1 + Div. 2)
A. Divide and Multiply
It can be found that it is optimal to multiply only one number at a time. Because the range is very small, you can enumerate which number to multiply by \ (2 \), and note that the answer is that the exponential level should be on \ (long~long \).
Posted on Wed, 01 Dec 2021 18:38:56 -0500 by StealthRider
Force buckle: 2087. Minimum cost of robot home in grid graph
When you get the title, you must read it first!!!!! To sum up: This is the brain turn to TM.... 1. At first glance, it is very similar to our usual robot walking problem. We must read the question carefully! 2. His cost calculation rule is to go to line I a ...
Posted on Mon, 29 Nov 2021 04:59:14 -0500 by netrepsa
For two \(1\)~\(n\), define \(a,b\), orz(a,b)=max(a_1, b_1)+\)... (+max(a_n, b_n)\).
You need to find out how many pairs \((a,b)\) satisfy \(orz(a,b)\; \geq\ m\).
Two positive integers in a row\(n,m\).
One integer per line represents the answer. Modeling (9944353).
Posted on Wed, 24 Nov 2021 13:44:55 -0500 by pwes24
Minimum ring problem
Minimal ring of undirected graph
Floyd algorithm can be used to deal with the minimum ring problem. To be exact, calculate the smallest ring by the way.
Floyd algorithm can find the multi-source shortest path of undirected graph. It can ensure that the outermost loop to k is obtained between all vertices
Posted on Sun, 21 Nov 2021 16:47:34 -0500 by Fazer
1, Prefix tree
1. What is a prefix tree
Prefix tree generally refers to dictionary tree, which refers to a structure rather than a class of questions (note that the information is on the way of the tree)
The typical application is to count and sort a large number of strings (but not limited to strings), so it is often used by search e ...
Posted on Sat, 20 Nov 2021 09:37:06 -0500 by marlonbtx
Given an array of words and a length maxWidth, rearrange the words into text with exactly maxWidth characters per line and aligned left and right ends.
You should use "greedy algorithm" to place a given word; That is, put as many words in each line as possible. If necessary, you can fill in the space '' so that each line has exactly ...
Posted on Sat, 20 Nov 2021 02:57:28 -0500 by Beauchy
Problem - 1334C - Codeforces
Greedy question, xs, I thought it was dp at first glance, and then gave up decisively. At the end of the game, I asked hls what the transfer equation was. As a result, hls told me it was greedy, whine whine (although I felt I couldn't get out of it)
Some monsters have two attributes: ...
Posted on Fri, 12 Nov 2021 20:28:21 -0500 by alco19357
This classic \ (dp \) just can't do it, just can't.....
Except for the \ (dp \) array, everything else is similar to the problem solution, but it's useless....
Let \ (dp[len][x1][x2] \) mean that half the length of the palindrome string is \ (len \), the abscissa of the end point of the string starting from \ ((1,1) \) is \ (x1 \) ...
Posted on Fri, 05 Nov 2021 22:34:25 -0400 by aouriques
CF1479B1 Painting the Array I CF1479B1 Painting the Array II
The only difference between this question and CF1480D2 is that this question asks for the maximum possible solution
Posted on Sun, 03 Oct 2021 19:56:53 -0400 by cahamilton