20150812 常州培训 扫坑
1. 给出一个数的$absurd$值为:
[1]去掉前导后导0;[2]设去掉后的数为$x$,最后一位数为$p$,$x$的位数为$m$;[3]$absurd$值为:当$m=5$时,$absurd=2\times p-1$;否则,$absurd=2\times p$。
定义一个数$c$是$absurd$的,当且仅当在$[0.95c,1.05c]$内,存在一个数$d$,使得$d$的$absurd$值小于$c$的$absurd$值,那么就是$absurd$的。
5000组数据,每组数据给出$c$,求是否为$absurd$的。
法1:打表,总共281个数是$not absurd$的,存储即可。复杂度$O(281 \times T)$
法2:200以内的我们可以暴力处理;对于一个数c,我们先去零,然后找他前面和后面的3个数即可。
2. 一个傻逼$DynamicProgramming$= =
求最长连续段,若相同最大化段数。
3. kmp,我竟然没看出来
问两个时钟旋转后能否重合。
求差后,复制一遍,kmp匹配,如果匹配=n,那么就是possible,否则impossible。
我的情况:
t1t2 AC无压力
t3 哈希炸了,没判定先后,发现了好多问题
后来得知kmp太神了。orzorz
2024年1月10日 13:26
Pavzi.com provides all the news about Gadgets, the Economy, Technology, Business, Finance and many more. The main concept or our aim behind this website has been the will to provide resources with full information on each topic which can be accessed through the Internet. To ensure that every reader gets what is important and worthy about the topic they search and link to hear from us. pavzi.com Our site is a multiple Niche or category website which will ensure to provide information and resources on each and every topic. Some of the evergreen topics you will see on our website are Career, Job Recruitment, Educational, Technology, Reviews and others. We are targeting mostly so it is true that Tech, Finance, and Product Reviews. The only reason we have started this website is to make this site the need for your daily search use.