- 博客(86)
- 收藏
- 关注
转载 关于新世界的大门(新博客地址:BBBob.cf)
更新:BBBob.cf 这个域名已经不用了(但是依旧可以访问),永久域名改为了BBBob.win新博客地址为BBBob.cf,以后的博客都会在新博客更新,当然在新博客上我也会写得更用心些,不再像这里一样随意贴代码了事>_<至于为什么会写这篇博文.......因为我居然看到有人在百度搜BBBob.cf 进到了这里。。。。我自己也在百度试了一下这个搜索词,发现在第二页...
2017-07-28 11:23:00
174
转载 给sunpinyin加速
因为sunpinyin词库一大就会卡,因此需要自己添加一个脚本给sunpinyin加速。加速的原理就是把词库添加到内存,现在内存都这么大,根本不在乎这么几兆,当然输入体验更重要啦~首先先建一个脚本实现把词库放到内存中的功能,脚本就取名为sunpinyin_speed_up吧。#!/bin/sh# Capture the exit signal, make su...
2017-07-01 20:57:00
150
转载 利用fontforge制作自己的字体
最近手伤了,写代码特别慢,索性就干干一些奇奇怪怪的事情。发现我电脑上的中文字体很是奇怪,于是便去找了中英混合的等宽字体。满足条件的只找到了YaHei Consolas Hybrid,是微软的Consolas和雅黑的混合字体,发现除了`和’难以区分之外都很符合我的需求,于是便下了下来。然而用上了之后发现居然不支持powerline,这让我很是头痛,因此便开始了合并制作字体之旅,...
2017-06-24 15:42:00
1183
转载 CF586D. Phillip and Trains
1 /* 2 CF586D. Phillip and Trains 3 http://codeforces.com/problemset/problem/586/D 4 搜索 5 */ 6 #include<cstdio> 7 #include<algorithm> 8 #include<string.h>...
2017-04-27 11:44:00
123
转载 LightOJ 1370 Bi-shoe and Phi-shoe
1 /* 2 LightOJ 1370 Bi-shoe and Phi-shoe 3 http://lightoj.com/login_main.php?url=volume_showproblem.php?problem=1370 4 数论 欧拉函数 5 坑点是答案会爆int!!!! 6 */ 7 #include <cstdio>...
2017-04-25 15:59:00
128
转载 CF410div2 B. Mike and strings
1 /* 2 CF410div2 B. Mike and strings 3 http://codeforces.com/contest/798/problem/B 4 字符串 暴力 5 题意:给你n个串,每次操作可以将某个串的第一个字符放到最后去, 6 问最少的次数,使得所有字符串都相同 7 思路:先将所有字符串复制成二倍,然后暴力枚举要变成的...
2017-04-23 10:34:00
109
转载 CF410div2 A. Mike and palindrome
1 /* 2 CF410div2 A. Mike and palindrome 3 http://codeforces.com/contest/798/problem/A 4 水题 5 */ 6 #include <cstdio> 7 #include <algorithm> 8 #include <cstring&...
2017-04-23 09:42:00
92
转载 CF410div2 D. Mike and distribution
1 /* 2 CF410div2 D. Mike and distribution 3 http://codeforces.com/contest/798/problem/D 4 构造 5 题意:给出两个数列a,b,求选出n/2+1个数对,使得其和的二倍大于各自的数列 6 思路:对数列a进行排序,因为可以选一半加1个,所以最大的那个我们选出来 7...
2017-04-23 09:34:00
101
转载 CF798 C. Mike and gcd problem
1 /* 2 CF798 C. Mike and gcd problem 3 http://codeforces.com/contest/798/problem/C 4 数论 贪心 5 题意:如果一个数列的gcd值大于1,则称之为美丽数列 6 给出数列a,可以将a_i 和 a_(i+1)换为其差和其和 7 如果可以变为美丽数列,输出Y...
2017-04-22 02:29:00
174
转载 LightOJ1282 Leading and Trailing
1 /* 2 LightOJ1282 Leading and Trailing 3 http://lightoj.com/login_main.php?url=volume_showproblem.php?problem=1282 4 数论 fmod 5 fmod题。 6 求n^k的前三位 7 n可以写成10^a(a为小数)的形式。 8 因...
2017-04-14 20:02:00
132
转载 LightOJ1245 Harmonic Number (II)
1 /* 2 LightOJ1245 Harmonic Number (II) 3 http://lightoj.com/login_main.php?url=volume_showproblem.php?problem=1245 4 数论 求和 5 */ 6 #include <cstdio> 7 #include <algori...
2017-04-14 14:26:00
127
转载 LightOJ1234 Harmonic Number
1 /* 2 LightOJ1234 Harmonic Number 3 http://lightoj.com/login_main.php?url=volume_showproblem.php?problem=1234 4 打表 分块 5 由于只有加法运算,1e8时间是可以承受的。 6 然而空间无法承受,于是以50个单位为一块进行分块。 7 ...
2017-04-13 19:31:00
152
转载 POJ2115 C Looooops
1 /* 2 POJ2115 C Looooops 3 http://poj.org/problem?id=2115 4 扩展欧几里得 5 题意:求x, s.t. (a+c*x)=b (mod 1<<k) 6 <=> c*x=b-a (mod 1<<k) 7 */ 8 #include <...
2017-04-13 08:37:00
93
转载 POJ2116 Death to Binary?
1 /* 2 POJ2116 Death to Binary? 3 http://poj.org/problem?id=2116 4 齐肯多夫定理 5 6 */ 7 #include <cstdio> 8 #include <algorithm> 9 #include <cstring>...
2017-04-12 11:14:00
114
转载 POJ3318 Matrix Multiplication
1 /* 2 POJ3318 Matrix Multiplication 3 http://poj.org/problem?id=3318 4 随机化算法 矩阵 5 随机一个1×n的矩阵h 6 在ab=c左右两边左乘h 7 验证是否相等 8 然而不知道为什么g++交就会RE, 9 c++交AC 10 * 1...
2017-04-06 13:49:00
158
转载 祝我家小璐璐生日快乐
今天是璐璐的生日啦!有我的第一个生日哦~以后璐璐的每一个生日,都会有我陪伴????最后,爱生活,爱璐璐!转载于:https://www.cnblogs.com/BBBob/p/6667026.html...
2017-04-05 00:00:00
103
转载 HDU4569 Special equations
1 /* 2 HDU4569 Special equations 3 http://acm.hdu.edu.cn/showproblem.php?pid=4569 4 数论 5 题意:f(x)为一n次方程求是否存在x, s.t. f(x)=0 (mod p^2) 6 其中p为质数 7 首先,我们只需考虑0-p中的x即可,因为其他的x总可以先取模...
2017-04-02 00:22:00
188
转载 HDU4572 Bottles Arrangement
1 /* 2 HDU4572 Bottles Arrangement 3 http://acm.hdu.edu.cn/showproblem.php?pid=4572 4 数论 找规律 5 题意:有m行n列和1-n的数各n个,将其填在m×n的格子里 6 要求同一列中的数各不相同,同一行中相邻两数的差的绝对值不超过1。 7 求每一行中值的和的最小值...
2017-04-02 00:11:00
120
转载 HDU4565 So Easy!
1 /* 2 HDU4565 So Easy! 3 http://acm.hdu.edu.cn/showproblem.php?pid=4565 4 数论 快速幂 矩阵快速幂 5 题意:求[(a+sqrt(b))^n ]%m [ ]代表向上取证 6 联想到斐波那契数列,所以第一感觉是矩阵快速幂 7 后来发现根本不用这么麻烦,我们认为...
2017-04-01 23:59:00
207
转载 CF789B. Masha and geometric depression
1 /* 2 CF789B. Masha and geometric depression 3 http://codeforces.com/contest/789/problem/B 4 水题 5 各种特判,贼烦 6 */ 7 #include <cstdio> 8 #include <algorithm>...
2017-03-30 12:02:00
178
转载 CF789A. Anastasia and pebbles
1 /* 2 CF789A. Anastasia and pebbles 3 http://codeforces.com/contest/789/problem/A 4 水题 5 题意:有两个背包,每次分别可取k个物品,要求每次背包中的物品都是一种 6 问要取多少次。 7 对于每种物品,都要取ceil(n/k)次,因此只要加起来再除以2就是答案...
2017-03-30 12:01:00
139
转载 CF789C. Functions again
1 /* 2 CF789C. Functions again 3 http://codeforces.com/contest/789/problem/C 4 水题 5 题意:求数组中的连续和的最大值 6 */ 7 #include <cstdio> 8 #include <algorithm> 9 #include ...
2017-03-30 11:55:00
205
转载 HDU2161 Primes
1 /* 2 HDU2161 Primes 3 http://acm.hdu.edu.cn/showproblem.php?pid=2161 4 数论 水题 5 注意输入截止条件是n<=0 6 */ 7 #include <cstdio> 8 #include <algorithm> 9 #include &l...
2017-03-29 20:46:00
86
转载 UVA11752 The Super Powers
1 /* 2 UVA11752 The Super Powers 3 https://vjudge.net/contest/153365#problem/Y 4 数论 5 注意a^n=b要用除法求,并且求得的n比实际大1 6 */ 7 #include <cstdio> 8 #include <algorithm>...
2017-03-29 20:28:00
87
转载 UVA11827 Maximum GCD
1 /* 2 UVA11827 Maximum GCD 3 https://vjudge.net/contest/153365#problem/V 4 数论 gcd 5 水题,然而读入比较坑 6 * 7 */ 8 #include <cstdio> 9 #include <algorithm>10 #incl...
2017-03-29 18:58:00
138
转载 Tsinsen A1206. 小Z的袜子
1 /* 2 Tsinsen A1206. 小Z的袜子 3 http://www.tsinsen.com/new/A1206 4 BZOJ 2038: [2009国家集训队]小Z的袜子(hose) 5 http://www.lydsy.com/JudgeOnline/problem.php?id=2038 6 莫队算法 7 */...
2017-03-28 22:17:00
130
转载 CF617E. XOR and Favorite Number
1 /* 2 CF617E. XOR and Favorite Number 3 http://codeforces.com/contest/617/problem/E 4 莫队算法 5 题意:求l,r区间内异或和为k的对数 6 用times记录某异或值在当前区间中的个数 7 */ 8 #include <cstdio> 9 ...
2017-03-28 20:39:00
110
转载 BJFU fudq的等式
1 /* 2 BJFU fudq的等式 3 http://101.200.220.237/contest/19/problem/118/ 4 数论 勒让德定理 二分答案 5 */ 6 #include <cstdio> 7 #include <algorithm> 8 #include <cstrin...
2017-03-28 19:04:00
129
转载 BJFU 质数相关
1 /* 2 BJFU 质数相关 3 http://101.200.220.237/contest/19/problem/116/ 4 二分图 5 按质因数奇偶性建立二分图 6 * 7 * 8 */ 9 #include <cstdio> 10 #include <algorithm>...
2017-03-28 19:02:00
99
转载 CF55C. Pie or die
1 /* 2 CF55C. Pie or die 3 http://codeforces.com/problemset/problem/55/C 4 博弈论 乱搞 5 获胜条件是存在一个棋子到边界的值小于5 6 */ 7 #include <cstdio> 8 int main() 9 {10 int n,m,k;...
2017-03-27 16:39:00
125
转载 CF15C. Industrial Nim
1 /* 2 CF15C. Industrial Nim 3 http://codeforces.com/problemset/problem/15/C 4 数论 博弈论 尼姆博弈 5 6 典型的尼姆博弈,答案就是所有数的异或值 7 然而在1e16的数据范围下直接异或肯定会T 8 考虑以一个能被4整除的数开始的连续4n个数的异或和为0 ...
2017-03-27 16:26:00
117
转载 POJ2389 Bull Math
1 /* 2 POJ2389 Bull Math 3 http://poj.org/problem?id=2389 4 高精度乘法 5 * 6 */ 7 #include <cstring> 8 #include <cstdio> 9 #include <algorithm> 10 ...
2017-03-27 14:54:00
148
转载 HDU1002 A + B Problem II
1 /* 2 HDU1002 A + B Problem II 3 http://acm.hdu.edu.cn/showproblem.php?pid=1002 4 高精度加法 5 * 6 */ 7 #include <cstring> 8 #include <cstdio> 9 #include ...
2017-03-27 14:44:00
159
转载 HDU5514 Frogs
1 /* 2 HDU5514 Frogs 3 http://acm.hdu.edu.cn/showproblem.php?pid=5514 4 容斥原理 5 * 6 * 7 */ 8 #include <cstdio> 9 #include <cmath>10 #include <algorithm>...
2017-03-27 00:10:00
65
转载 HDU5130 Signal Interference
1 /* 2 HDU5130 Signal Interference 3 http://acm.hdu.edu.cn/showproblem.php?pid=5130 4 计算几何 圆与多边形面积交 5 * 6 */ 7 8 9 #include <cstdio> 10 #include <alg...
2017-03-27 00:08:00
271
转载 CF786A - Berzerk
1 /* 2 CF786A - Berzerk 3 http://codeforces.com/contest/786/problem/A 4 博弈论 5 直接搜出NP状态图。记得要记忆化剪枝。 6 * 7 */ 8 #include <cstdio> 9 #include <cstring>...
2017-03-24 17:53:00
225
转载 CF787A - The Monster
1 /* 2 CF787A - The Monster 3 http://codeforces.com/contest/787/problem/A 4 数学 扩展欧几里得 5 注意x或y为0的时候要特判 6 并且结果要大于b和d 7 */ 8 #include <cstdio> 9 int ex_gcd(int a,int b...
2017-03-24 14:44:00
128
转载 CF449 C. Jzzhu and Apples
1 /* 2 http://codeforces.com/problemset/problem/449/C 3 cf 449 C. Jzzhu and Apples 4 数论+素数+贪心 5 */ 6 #include <cstdio> 7 #include <algorithm> 8 using namespace std;...
2017-03-24 13:22:00
121
转载 CF396B. On Sum of Fractions
1 /* 2 cf396B. On Sum of Fractions 3 http://codeforces.com/problemset/problem/396/B 4 数论+裂项求和+素数筛+gcd 5 */ 6 #include <cstdio> 7 #include <algorithm> 8 #inclu...
2017-03-24 13:21:00
124
转载 CF369E. ZS and The Birthday Paradox
1 /* 2 cf369E. ZS and The Birthday Paradox 3 http://codeforces.com/contest/711/problem/E 4 抽屉原理+快速幂+逆元+勒让德定理+费马小定理+欧拉定理+数论 5 题解:https://amoshyc.github.io/ojsolution-build/cf/cf369/pe.h...
2017-03-24 13:19:00
160
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人