04 2020 档案
摘要:"洛谷链接" 题目 Although Inzane successfully found his beloved bone, Zane, his owner, has yet to return. To search for Zane, he would need a lot of money, o
阅读全文
摘要:题目 Farmer John正在一个新的销售区域对他的牛奶销售方案进行调查。他想把牛奶送到T个城镇 $(1 5,4 6和1 3,花费分别是 100, 100, 10。FJ的中心城镇在城镇4。 输出样例 样例输出解释 FJ的奶牛从4号城镇开始,可以通过道路到达3号城镇。然后他们会通过航线达到5和6号城
阅读全文
摘要:题目 For their physical fitness program, $N (2 ≤ N ≤ 1,000,000)$ cows have decided to run a relay race using the $T (2 ≤ T ≤ 100)$ cow trails throughout
阅读全文
摘要:The only difference between the easy and the hard versions is the maximum value of $k$. You are given an infinite sequence of form "112123123412345…"
阅读全文
摘要:题目 米特是D星球上一种非常神秘的物质,蕴含着巨大的能量。在以米特为主要能源的D星上,这种米特能源的运输和储存一直是一个大问题。D星上有N个城市,我们将其顺序编号为1到N,1号城市为首都。这N个城市由N 1条单向高速通道连接起来,构成一棵以1号城市(首部)为根的树,高速通道的方向由树中的儿子指向父亲
阅读全文
摘要:题目 Given a list of N integers with absolute values no larger than $10^{15}$, find a non empty subset of these numbers which minimizes the absolute val
阅读全文
摘要:题目 Z 国的骑士团是一个很有势力的组织,帮会中汇聚了来自各地的精英。他们劫富济贫,惩恶扬善,受到社会各界的赞扬。 最近发生了一件可怕的事情,邪恶的 Y 国发动了一场针对 Z 国的侵略战争。战火绵延五百里,在和平环境中安逸了数百年的 Z 国又怎能抵挡的住 Y 国的军队。于是人们把所有的希望都寄托在了
阅读全文
摘要:"Codeforces 1215D Ticket Game 原题" 题目 Monocarp and Bicarp live in Berland, where every bus ticket consists of n digits (n is an even number). During th
阅读全文
摘要:题目 \ define xhxj (Xin Hang senior sister(学姐)) If you do not know xhxj, then carefully reading the entire description is very important. As the stronge
阅读全文
摘要:题目 Slastyona and her loyal dog Pushok are playing a meaningless game that is indeed very interesting. The game consists of multiple rounds. Its rules
阅读全文
摘要:题目 Volodya is an odd boy and his taste is strange as well. It seems to him that a positive integer number is beautiful if and only if it is divisible
阅读全文
摘要:题目 本题中,我们将用符号 \(\lfloor c \rfloor\) 表示对 \(c\) 向下取整,例如:\(\lfloor 3.0 \rfloor = \lfloor 3.1 \rfloor = \lfloor 3.9 \rfloor = 3\)。 蛐蛐国最近蚯蚓成灾了!隔壁跳蚤国的跳蚤也拿蚯蚓
阅读全文
摘要:题目 是不是平时在手机里玩吃豆豆游戏玩腻了呢?最近MOKIA手机上推出了一种新的围豆豆游戏,大家一起来试一试吧。 游戏的规则非常简单,在一个N×M的矩阵方格内分布着D颗豆子,每颗豆有不同的分值Vi。游戏者可以选择任意一个方格作为起始格,每次移动可以随意的走到相邻的四个格子,直到最终又回到起始格。最终
阅读全文
摘要:题目 An army of ants walk on a horizontal pole of length l cm, each with a constant speed of 1 cm/s. When a walking ant reaches an end of the pole, it i
阅读全文
摘要:题目 The first stage of train system reform (that has been described in the problem Railways of the third stage of 14th Polish OI. However, one needs no
阅读全文
摘要:题目 B君在围观一群男生和一群女生玩游戏,具体来说游戏是这样的: 给出一棵n个节点的树,这棵树的每条边有一个权值,这个权值只可能是0或1。 在一局游戏开始时,会确定一个节点作为根。接下来从女生开始,双方轮流进行操作。 当一方操作时,他们需要先选择一个不为根的点,满足该点到其父亲的边权为1; 然后找出
阅读全文
摘要:题目 On another floor of the A.R.C. Markland N, the young man Simon "Xenon" Jackson, takes a break after finishing his project early (as always). Having
阅读全文
摘要:The Japanese government plans to increase the number of inbound tourists to forty million in the year 2020, and sixty million in 2030. Not only increa
阅读全文
摘要:题目描述 Chris家的电话铃响起了,里面传出了Chris的老师焦急的声音:“喂,是Chris的家长吗?你们的孩子又没来上课,不想参加考试了吗?”一听说要考试,Chris的父母就心急如焚,他们决定在尽量短的时间内找到Chris。他们告诉Chris的老师:“根据以往的经验,Chris现在必然躲在朋友S
阅读全文
摘要:题目 A Communist regime is trying to redistribute wealth in a village. They have have decided to sit everyone around a circular table. First, everyone h
阅读全文
摘要:题目 Farmer John has arranged his N $(1 ≤ N ≤ 5,000)$ cows in a row and many of them are facing forward, like good cows. Some of them are facing backwar
阅读全文
摘要:题目 In a village called Byteville, there are $n$ houses connected with $n 1$ roads. For each pair of houses, there is a unique way to get from one to a
阅读全文
摘要:题目 一棵二叉树可以按照如下规则表示成一个由0、1、2组成的字符序列,我们称之为"二叉树序列S": $$ S=\left\{ \begin{aligned} 0 &\ \ 表示该树没有子节点 \\ 1S_1 &\ \ 表示该树有一个子节点,S_1为其子树的二叉树序列 \\ 2S_1S_2 &\ \
阅读全文
摘要:题目 某售货员小T要到若干城镇去推销商品,由于该地区是交通不便的山区,任意两个城镇之间都只有唯一的可能经过其它城镇的路线。小T可以准确地估计出在每个城镇停留的净收益。这些净收益可能是负数,即推销商品的利润抵不上花费。由于交通不便,小T经过每个城镇都需要停留,在每个城镇的停留次数与在该地的净收益无关,
阅读全文
摘要:题目 NEKO ΦωΦ has just got a new maze game on her PC! The game's main puzzle is a maze, in the forms of a $2×n$ rectangle grid. NEKO's task is to lead a
阅读全文