codeforces
文章平均质量分 72
炸毛疯兔
这个作者很懒,什么都没留下…
展开
-
CF3A Shortest path of the king
题目描述The king is left alone on the chessboard. In spite of this loneliness, he doesn't lose heart, because he has business of national importance. For example, he has to pay an official visit to squarett. As the king is not in habit of wasting his time,..原创 2021-09-28 16:39:56 · 145 阅读 · 0 评论 -
1560D - Make a Power of Two(Codeforces)
题目大意:T组数据 每一组数据输入一个数字a 你可以对数字a的任何一位数字进行删除或者在任意位置的右面插入一个新的数字 求用最少的操作次数使a转换成2的幂次例如1052 ->102(删掉5)->1024(在2后加4)888->88(删掉8)->8(删掉8)思路:可以用vector 将所有的2的幂次存起来 对每个进行判断求公共子序列的长度a转换成b有两步 1.删除a中的除公共子序列外的数 2.加上b中除公共子序列的数#include<iostream&g原创 2021-08-23 13:00:47 · 161 阅读 · 0 评论 -
B. Obsession with Robots
The whole world got obsessed with robots,and to keep pace with the progress, great Berland's programmer Draude decided to build his own robot. He was working hard at the robot. He taught it to walk the shortest path from one point to another, to record all原创 2021-08-03 21:48:42 · 228 阅读 · 0 评论 -
Hard Work(CF61B)
题目描述After the contest in comparing numbers, Shapur's teacher found out that he is a real genius and that no one could possibly do the calculations faster than him even using a super computer!Some days before the contest, the teacher took a very simple-原创 2021-08-03 18:14:29 · 202 阅读 · 0 评论