CF618F, CF1836E, and the Beijing College Entrance Exam

Правка en4, от dfsof, 2023-06-21 20:49:17

These three problems are almost the same.

CF618F [Double Knapsack]: https://codeforces.net/problemset/problem/618/F

CF1836E [Twin Cluster]: https://codeforces.net/contest/1836/problem/E

Beijing College Entrance Exam:

Given two positive integer arrays $$$A$$$ and $$$B$$$, such that:

$$$len(A) = len(B) = n$$$

and

$$$\forall 1 \leq i \leq n$$$, $$$1 \leq a_i, b_i \leq n$$$.

Prove there are subsegments $$$[x, y] \subseteq [1, n]$$$, $$$[z, w] \subseteq [1, n]$$$ such that $$$\sum\limits_{i=x}^y A[i] = \sum\limits_{j=z}^w B[j]$$$. For example, $$$n=4, A=[1,2,3,4], B=[4,4,4,4]$$$, then $$$x=4, y=4, z=1, w=1$$$ is a solution.

Теги pigeonhole principle

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en4 Английский dfsof 2023-06-21 20:49:17 137 (published)
en3 Английский dfsof 2023-06-21 20:46:55 130
en2 Английский dfsof 2023-06-21 20:45:17 8 Tiny change: '\n\nfor $\all 1 \leq i ' -> '\n\nfor $\every 1 \leq i '
en1 Английский dfsof 2023-06-21 20:45:04 438 Initial revision (saved to drafts)