上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 26 下一页
摘要: 每次交换:逆序对的数量+1或者-1; 假设最后逆序对数量为 sum; ①x+y=3n; ②x-y=sum; -> 3n+sum为偶数; 所以 n 和 sum 必须奇偶一样; 阅读全文
posted @ 2019-01-15 18:50 NKDEWSM 阅读(247) 评论(0) 推荐(0) 编辑
摘要: 题目描述 Some company is going to hold a fair in Byteland. There are n n n towns in Byteland and m m m two-way roads between towns. Of course, you can rea 阅读全文
posted @ 2019-01-15 18:46 NKDEWSM 阅读(808) 评论(0) 推荐(0) 编辑
摘要: 题意翻译 题目大意: nnn个位置,每个位置有两个属性s,cs,cs,c,要求选择3个位置i,j,ki,j,ki,j,k,使得si<sj<sks_i<s_j<s_ksi​<sj​<sk​,并使得ci+cj+ckc_i+c_j+c_kci​+cj​+ck​最小 输入格式: 一行一个整数,nnn,3<= 阅读全文
posted @ 2019-01-15 18:38 NKDEWSM 阅读(624) 评论(0) 推荐(0) 编辑
摘要: 题意翻译 题目大意 输入一个 xxx ,一个 yyy ,求是 xyx^yxy 大还是 yxy^xyx 大。 (1≤x,y≤109)(1≤x,y≤10^9)(1≤x,y≤109) 输入输出格式 输入格式 一行,两个整数 x,yx,yx,y 。 输出格式 若 xyx^yxy > yxy^xyx ,输出" 阅读全文
posted @ 2019-01-15 18:36 NKDEWSM 阅读(237) 评论(0) 推荐(0) 编辑
摘要: You took a peek on Thanos wearing Infinity Gauntlet. In the Gauntlet there is a place for six Infinity Gems: the Power Gem of purple color, the Time G 阅读全文
posted @ 2019-01-15 18:34 NKDEWSM 阅读(309) 评论(0) 推荐(0) 编辑
摘要: 题目描述 Although Farmer John has no problems walking around the fair to collect prizes or see the shows, his cows are not in such good shape; a full day 阅读全文
posted @ 2019-01-15 10:36 NKDEWSM 阅读(233) 评论(0) 推荐(0) 编辑
摘要: 题目描述 佳佳碰到了一个难题,请你来帮忙解决。 对于不定方程a1+a2+…+ak-1+ak=g(x),其中k≥2且k∈N,x是正整数,g(x)=x^x mod 1000(即x^x除以1000的余数),x,k是给定的数。我们要求的是这个不定方程的正整数解组数。 举例来说,当k=3,x=2时,分别为(a 阅读全文
posted @ 2019-01-15 09:33 NKDEWSM 阅读(316) 评论(0) 推荐(0) 编辑
摘要: 题目背景 阿宝上学了,今天老师拿来了一块很长的涂色板。 题目描述 色板长度为L,L是一个正整数,所以我们可以均匀地将它划分成L块1厘米长的小方格。并从左到右标记为1, 2, ... L。 现在色板上只有一个颜色,老师告诉阿宝在色板上只能做两件事: "C A B C" 指在A到 B 号方格中涂上颜色 阅读全文
posted @ 2019-01-14 19:45 NKDEWSM 阅读(222) 评论(0) 推荐(0) 编辑
摘要: 题目背景 滚粗了的HansBug在收拾旧语文书,然而他发现了什么奇妙的东西。 题目描述 蒟蒻HansBug在一本语文书里面发现了一本答案,然而他却明明记得这书应该还包含一份练习题。然而出现在他眼前的书多得数不胜数,其中有书,有答案,有练习册。已知一个完整的书册均应该包含且仅包含一本书、一本练习册和一 阅读全文
posted @ 2019-01-14 17:11 NKDEWSM 阅读(155) 评论(0) 推荐(0) 编辑
摘要: 题目描述 Farmer John's N cows (1 ≤ N ≤ 100,000) share many similarities. In fact, FJ has been able to narrow down the list of features shared by his cows 阅读全文
posted @ 2019-01-14 16:08 NKDEWSM 阅读(238) 评论(0) 推荐(0) 编辑
上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 26 下一页