Loading

上一页 1 ··· 57 58 59 60 61 62 63 64 65 ··· 74 下一页
摘要: 题目背景 题目描述: 每天,农夫 John 的N(1 <= N <= 50,000)头牛总是按同一序列排队. 有一天, John 决定让一些牛们玩一场飞盘比赛. 他准备找一群在对列中为置连续的牛来进行比赛. 但是为了避免水平悬殊,牛的身高不应该相差太大. John 准备了Q (1 <= Q <= 1 阅读全文
posted @ 2020-03-30 21:12 脂环 阅读(193) 评论(0) 推荐(0) 编辑
摘要: Advanced CPU Manufacturer (ACM) is one of the best CPU manufacturer in the world. Every day, they manufacture n CPU chips and sell them all over the w 阅读全文
posted @ 2020-03-30 20:11 脂环 阅读(153) 评论(0) 推荐(0) 编辑
摘要: 有时候快排/归并之类并不简简单单只是排序,比如快排可以求第k大,归并在部分已排序的情况下效率较高不容易被卡~ #include <bits/stdc++.h> using namespace std; void merge(int a[], int l, int r, int mid) { int 阅读全文
posted @ 2020-03-29 20:06 脂环 阅读(129) 评论(0) 推荐(0) 编辑
摘要: Vova had a pretty weird sleeping schedule. There are hh hours in a day. Vova will sleep exactly nn times. The ii -th time he will sleep exactly after 阅读全文
posted @ 2020-03-29 00:54 脂环 阅读(195) 评论(0) 推荐(0) 编辑
摘要: The next lecture in a high school requires two topics to be discussed. The ii -th topic is interesting by aiai units for the teacher and by bibi units 阅读全文
posted @ 2020-03-29 00:42 脂环 阅读(249) 评论(0) 推荐(0) 编辑
摘要: There is a frog staying to the left of the string s=s1s2…sns=s1s2…sn consisting of nn characters (to be more precise, the frog initially stays at the 阅读全文
posted @ 2020-03-29 00:35 脂环 阅读(362) 评论(0) 推荐(0) 编辑
摘要: Problem Statement Snuke has decided to play a game using cards. He has a deck consisting of NN cards. On the ii -th card from the top, an integer AiAi 阅读全文
posted @ 2020-03-29 00:30 脂环 阅读(234) 评论(0) 推荐(0) 编辑
摘要: 题目背景 BBB地区在地震过后,所有村庄都造成了一定的损毁,而这场地震却没对公路造成什么影响。但是在村庄重建好之前,所有与未重建完成的村庄的公路均无法通车。换句话说,只有连接着两个重建完成的村庄的公路才能通车,只能到达重建完成的村庄。 题目描述 给出BBB地区的村庄数NNN,村庄编号从000到N−1 阅读全文
posted @ 2020-03-28 18:55 脂环 阅读(135) 评论(0) 推荐(0) 编辑
摘要: The round carousel consists of nn figures of animals. Figures are numbered from 11 to nn in order of the carousel moving. Thus, after the nn -th figur 阅读全文
posted @ 2020-03-27 23:56 脂环 阅读(193) 评论(0) 推荐(0) 编辑
摘要: A number is ternary if it contains only digits 00 , 11 and 22 . For example, the following numbers are ternary: 10221022 , 1111 , 2121 , 20022002 . Yo 阅读全文
posted @ 2020-03-27 08:45 脂环 阅读(201) 评论(0) 推荐(0) 编辑
上一页 1 ··· 57 58 59 60 61 62 63 64 65 ··· 74 下一页