随笔分类 - Codeforces
摘要:C. Swap Game Alice and Bob are playing a game on an array of positive integers. Alice and Bob make alternating moves with Alice going first. I
阅读全文
摘要:C1. Sheikh (Easy version) This is the easy version of the problem. The only difference is that in this version . You are given an array of intege
阅读全文
摘要:D. Factorial Divisibility You are given an integer and an array of integers . You have to determine if the number $a_1!+a_2!+
阅读全文
摘要:F. MEX vs MED You are given a permutation of length of numbers . Count the number of subsegments $1 \leq l \l
阅读全文
摘要:E. FTL Monocarp is playing a video game. In the game, he controls a spaceship and has to destroy an enemy spaceship. Monocarp has two lasers installed
阅读全文
摘要:C1. Make Nonzero Sum (easy version) This is the easy version of the problem. The difference is that in this version the array can not contain zeros. Y
阅读全文
摘要:D1. Balance (Easy version) This is the easy version of the problem. The only difference is that in this version there are no "remove" queries. Initial
阅读全文
摘要:B. Ugu A binary string is a string consisting only of the characters and . You are given a binary string . It is necessary t
阅读全文
摘要:A. Bestie You are given an array consisting of integers . Friends asked you to make the greatest common divisor (GCD) of
阅读全文
摘要:D. Problem with Random Tests You are given a string consisting of characters. Each character of is either or . A substring of i
阅读全文
摘要:C. Save the Magazines Monocarp has been collecting rare magazines for quite a while, and now he has decided to sell them. He distributed the magazines
阅读全文
摘要:E2. Divisible Numbers (hard version) This is an hard version of the problem. The only difference between an easy and a hard version is the constraints
阅读全文
摘要:E1. Divisible Numbers (easy version) This is an easy version of the problem. The only difference between an easy and a hard version is the constraints
阅读全文
摘要:F. Multi-Colored Segments Dmitry has segments of different colors on the coordinate axis . Each segment is characterized by three integers $l_
阅读全文
摘要:E. Sending a Sequence Over the Network The sequence is sent over the network as follows: sequence is split into segments (each element of the
阅读全文
摘要:D. Equal Binary Subsequences Everool has a binary string of length . Note that a binary string is a string consisting of only characters a
阅读全文
摘要:C1. Good Subarrays (Easy Version) This is the easy version of this problem. In this version, we do not have queries. Note that we have multiple test c
阅读全文
摘要:B. Playing with GCD You are given an integer array of length . Does there exist an array consisting of positive integers such that $a
阅读全文