ICode9

精准搜索请尝试: 精确搜索
  • POJ 2609 DP 双队列DP2020-12-07 11:04:18

    POJ 2609 DP 双队列DP 题意 给出队列容量与一组数,并且我们有两个这样容量的空队列,要求我们按照次序把数装进两个队列中,输出最多能装多少以及每个数装进哪个队列。 思路 由于按照次序来装,不能跳过,所以我们可以使用DP寻路的思想来做。状态可以设置为: \[F_{i, j, k} = 前i个数,左

  • 如何查看CPU消耗最高的线程2020-06-08 17:08:14

    如何找出消耗CPU最多的线程?   1.使用 top -c 找出所有当前进程的运行列表   2. 按P对所有进程按CPU使用率进行排序,找出消耗最高的线程PID   3.使用 top -Hp PID,查出里面消耗最高的进程,继续按P排序   4.这个线程PID是十进制的,我们需要转换为十六进制 此时已经找到了消耗CPU

  • HDU-2609-How many(最小表示法)2019-09-27 15:56:00

    链接: https://vjudge.net/problem/HDU-2609 题意: Give you n ( n < 10000) necklaces ,the length of necklace will not large than 100,tell me How many kinds of necklaces total have.(if two necklaces can equal by rotating ,we say the two necklaces are some). Fo

  • hdu 2609 How many (最小表示法)2019-09-13 15:01:10

    题意 给 \(n\) 个循环串,求本质不同串的数量 传送门 思路 最小表示法求下标,从最小下标处作为串的起点,将新串放到map中去重,最终map中的元素数量即为最终答案。 最小/大表示法 Code #include <cstdio> #include <cstring> #include <map> #include <string> using namespace std; c

  • HDU 2609 How many [最小表示法]2019-05-07 13:49:22

    #Description 给n个字符串,如果循环同构,就算一组,问总共有几组 #Algorithm 将每个字符串转成最小表示,然后sort一下 #Code #include <cstdio> #include <algorithm> #include <iostream> using namespace std; const int maxn = 100010; int main() { int n; while (scanf("%

  • 随手练——HUD 2609 How many2019-02-08 14:40:51

    题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=2609 题目没看懂,就想百度找下,结果 多数人就写个 最小表示法,就po代码了,看了这个博主才明白题目是啥意思:https://blog.csdn.net/piaocoder/article/details/48447193 ,每个01序列都作为一串 “项链”,能够通过循环转换而成的算同

专注分享技术,共同学习,共同进步。侵权联系[81616952@qq.com]

Copyright (C)ICode9.com, All Rights Reserved.

ICode9版权所有