随笔分类 -  题库—Codeforces比赛

上一页 1 2 3 4 5 6 7 8 ··· 10 下一页
摘要:The length of the longest common prefix of two strings s=s1s2sn and t=t1t2tm is defined as the maximum integer k0≤k≤min*(n,*m)) such 阅读全文
posted @ 2020-08-02 21:54 脂环 阅读(216) 评论(0) 推荐(0) 编辑
摘要:Vladimir would like to prepare a present for his wife: they have an anniversary! He decided to buy her exactly nn flowers. Vladimir went to a flower s 阅读全文
posted @ 2020-07-20 15:59 脂环 阅读(277) 评论(0) 推荐(0) 编辑
摘要:Pasha loves to send strictly positive integers to his friends. Pasha cares about security, therefore when he wants to send an integer nn , he encrypts 阅读全文
posted @ 2020-07-20 00:23 脂环 阅读(441) 评论(0) 推荐(1) 编辑
摘要:Acacius is studying strings theory. Today he came with the following problem. You are given a string ss of length nn consisting of lowercase English l 阅读全文
posted @ 2020-07-19 21:07 脂环 阅读(453) 评论(0) 推荐(0) 编辑
摘要:You are given a graph consisting of nn vertices and mm edges. It is not guaranteed that the given graph is connected. Some edges are already directed 阅读全文
posted @ 2020-07-19 01:46 脂环 阅读(410) 评论(2) 推荐(0) 编辑
摘要:You are given a string s[1…n]s[1…n] consisting of lowercase Latin letters. It is guaranteed that n=2kn=2k for some integer k≥0k≥0 . The string s[1…n]s 阅读全文
posted @ 2020-07-18 17:09 脂环 阅读(396) 评论(0) 推荐(0) 编辑
摘要:You are given an array aa consisting of nn integers. You have to find the length of the smallest (shortest) prefix of elements you need to erase from 阅读全文
posted @ 2020-07-18 16:59 脂环 阅读(179) 评论(0) 推荐(0) 编辑
摘要:A permutation of length nn is a sequence of integers from 11 to nn of length nn containing each number exactly once. For example, [1][1] , [4,3,5,1,2] 阅读全文
posted @ 2020-07-18 16:48 脂环 阅读(458) 评论(0) 推荐(0) 编辑
摘要:You are given three positive (i.e. strictly greater than zero) integers xx , yy and zz . Your task is to find positive integers aa , bb and cc such th 阅读全文
posted @ 2020-07-18 16:47 脂环 阅读(510) 评论(0) 推荐(0) 编辑
摘要:There are nn programmers that you want to split into several non-empty teams. The skill of the ii -th programmer is aiai . You want to assemble the ma 阅读全文
posted @ 2020-07-14 09:30 脂环 阅读(257) 评论(0) 推荐(0) 编辑
摘要:You are given a permutation p1,p2,…,pnp1,p2,…,pn . Recall that sequence of nn integers is called a permutation if it contains all integers from 11 to 阅读全文
posted @ 2020-07-14 08:35 脂环 阅读(500) 评论(0) 推荐(0) 编辑
摘要:Recently, you found a bot to play "Rock paper scissors" with. Unfortunately, the bot uses quite a simple algorithm to play: he has a string s=s1s2…sns 阅读全文
posted @ 2020-07-14 08:32 脂环 阅读(368) 评论(0) 推荐(0) 编辑
摘要:Patrick likes to play baseball, but sometimes he will spend so many hours hitting home runs that his mind starts to get foggy! Patrick is sure that hi 阅读全文
posted @ 2020-07-13 15:34 脂环 阅读(235) 评论(0) 推荐(0) 编辑
摘要:In Omkar's last class of math, he learned about the least common multiple, or LCMLCM . LCM(a,b)LCM(a,b) is the smallest positive integer xx which is d 阅读全文
posted @ 2020-07-12 22:09 脂环 阅读(307) 评论(0) 推荐(0) 编辑
摘要:You have been blessed as a child of Omkar. To express your gratitude, please solve this problem for Omkar! An array aa of length nn is called complete 阅读全文
posted @ 2020-07-12 22:01 脂环 阅读(336) 评论(0) 推荐(0) 编辑
摘要:今天做完POJ2182,突然想起来这道很久以前没补的cf题了,这两个题思路惊人的相似2333. 借用某谷的翻译:你需要维护一个可重集。初始时里面有n个正整数{A1,A2,⋯An},它们的值域为[1,n]。现在有q个操作,共有两类:• 1,若k为负数,则删除排名为∣k∣的数字。若不存在排名为∣k∣的数 阅读全文
posted @ 2020-07-06 20:01 脂环 阅读(197) 评论(0) 推荐(0) 编辑
摘要:The last contest held on Johnny's favorite competitive programming platform has been received rather positively. However, Johnny's rating has dropped 阅读全文
posted @ 2020-06-07 21:37 脂环 阅读(300) 评论(0) 推荐(0) 编辑
摘要:Among Johnny's numerous hobbies, there are two seemingly harmless ones: applying bitwise operations and sneaking into his dad's office. As it is usual 阅读全文
posted @ 2020-06-07 21:33 脂环 阅读(305) 评论(0) 推荐(0) 编辑
摘要:Johnny has recently found an ancient, broken computer. The machine has only one register, which allows one to put in there one variable. Then in one o 阅读全文
posted @ 2020-06-07 21:31 脂环 阅读(282) 评论(0) 推荐(0) 编辑
摘要:Ashish has a tree consisting of nn nodes numbered 11 to nn rooted at node 11 . The ii -th node in the tree has a cost aiai , and binary digit bibi is 阅读全文
posted @ 2020-06-01 23:18 脂环 阅读(221) 评论(0) 推荐(0) 编辑

上一页 1 2 3 4 5 6 7 8 ··· 10 下一页
点击右上角即可分享
微信分享提示
主题色彩