Loading

摘要: An ascending sorted sequence of distinct values is one in which some form of a less-than operator is used to order the elements from smallest to large 阅读全文
posted @ 2020-02-12 17:46 脂环 阅读(157) 评论(0) 推荐(0) 编辑
摘要: 题目描述 CC C国有n n n个大城市和m mm 条道路,每条道路连接这 nnn个城市中的某两个城市。任意两个城市之间最多只有一条道路直接相连。这 mmm 条道路中有一部分为单向通行的道路,一部分为双向通行的道路,双向通行的道路在统计条数时也计为 11 1条。 CC C国幅员辽阔,各地的资源分布情 阅读全文
posted @ 2020-02-11 17:51 脂环 阅读(178) 评论(0) 推荐(0) 编辑
摘要: Bessie is out in the field and wants to get back to the barn to get as much sleep as possible before Farmer John wakes her for the morning milking. Be 阅读全文
posted @ 2020-02-11 13:20 脂环 阅读(187) 评论(0) 推荐(0) 编辑
摘要: Farmer John wants to set up a telephone line at his farm. Unfortunately, the phone company is uncooperative, so he needs to pay for some of the cables 阅读全文
posted @ 2020-02-11 03:11 脂环 阅读(195) 评论(0) 推荐(0) 编辑
摘要: Guy-Manuel and Thomas have an array aa of nn integers [a1,a2,…,an ]. In one step they can add 11 to any element of the array. Formally, in one step th 阅读全文
posted @ 2020-02-10 13:36 脂环 阅读(136) 评论(0) 推荐(0) 编辑
摘要: Anu has created her own function ff : f(x,y)=(x|y)−y where || denotes the bitwise OR operation. For example, f(11,6)=(11|6)−6=15−6=9. It can be proved 阅读全文
posted @ 2020-02-10 13:20 脂环 阅读(156) 评论(0) 推荐(0) 编辑
摘要: 题目描述 金明今天很开心,家里购置的新房就要领钥匙了,新房里有一间他自己专用的很宽敞的房间。更让他高兴的是,妈妈昨天对他说:“你的房间需要购买哪些物品,怎么布置,你说了算,只要不超过NNN元钱就行”。今天一早金明就开始做预算,但是他想买的东西太多了,肯定会超过妈妈限定的NNN元。于是,他把每件物品规 阅读全文
posted @ 2020-02-09 20:46 脂环 阅读(191) 评论(0) 推荐(0) 编辑
摘要: 题目描述 小渊和小轩是好朋友也是同班同学,他们在一起总有谈不完的话题。一次素质拓展活动中,班上同学安排做成一个 m 行 n 列的矩阵,而小渊和小轩被安排在矩阵对角线的两端,因此,他们就无法直接交谈了。幸运的是,他们可以通过传纸条来进行交流。纸条要经由许多同学传到对方手里,小渊坐在矩阵的左上角,坐标 阅读全文
posted @ 2020-02-09 14:43 脂环 阅读(161) 评论(0) 推荐(0) 编辑
摘要: 题目描述 This problem differs from one which was on the online contest. The sequence a1,a2,...,an a_{1},a_{2},...,a_{n} a1​,a2​,...,an​ is called increasi 阅读全文
posted @ 2020-02-09 00:19 脂环 阅读(231) 评论(0) 推荐(0) 编辑
摘要: 题目描述 设A和B是两个字符串。我们要用最少的字符操作次数,将字符串A转换为字符串B。这里所说的字符操作共有三种: 1、删除一个字符; 2、插入一个字符; 3、将一个字符改为另一个字符; !皆为小写字母! 输入格式 第一行为字符串A;第二行为字符串B;字符串A和B的长度均小于2000。 输出格式 只 阅读全文
posted @ 2020-02-07 14:46 脂环 阅读(174) 评论(0) 推荐(0) 编辑