返回顶部
上一页 1 2 3 4 5 6 ··· 16 下一页
摘要: https://www.acwing.com/problem/content/139/ cpp include using namespace std; typedef long long ll; typedef unsigned long long ull; int a[20]; ull ha[2 阅读全文
posted @ 2019-10-23 23:26 Inko 阅读(176) 评论(0) 推荐(0) 编辑
摘要: http://poj.org/problem?id=2299 求逆序对最简单的绝对不会是树状数组,一定是归并排序(认真),不过树状数组会不会快一点呢?理论上应该是树状数组快一点(假如不进行离散化)。 cpp include include include include include includ 阅读全文
posted @ 2019-10-23 23:13 Inko 阅读(102) 评论(0) 推荐(0) 编辑
摘要: http://poj.org/problem?id=1840 题意:求 $a_1x_1^3+a_2x_2^3+a_3x_3^3+a_4x_4^3+a_5x_5^3=0$ 的整数解,其中所有变量的取值都是 $[ 50,50]$ ,且 $x_i \neq 0$ 暴力枚举,但是要怎么分两半呢?事实证明是前 阅读全文
posted @ 2019-10-23 21:46 Inko 阅读(131) 评论(0) 推荐(0) 编辑
摘要: 普通的SPFA: 带SLF优化的SPFA,实测在某些数据上确实会快(有人说是15%左右,但实际上貌似不止?反正抖得厉害) 阅读全文
posted @ 2019-10-23 20:55 Inko 阅读(87) 评论(0) 推荐(0) 编辑
摘要: http://poj.org/problem?id=3259 看见500的数据量莽了一发Floyd,还T了。讲道理应该不至于的,换个快读试试。 cpp include include include include include include include include include in 阅读全文
posted @ 2019-10-23 20:45 Inko 阅读(73) 评论(0) 推荐(0) 编辑
摘要: http://poj.org/problem?id=1083 题意:有一个平面图形如下面的房间,中间的走廊一格只能容纳一次运输,一次运输会把要占用的格子一次性上锁,求最少要运几次? 感觉就是每次暴力把覆盖的格子++,然后最大的覆盖的格子就是答案。 貌似总是可以有办法使得他们不冲突。(直观感受) in 阅读全文
posted @ 2019-10-23 20:33 Inko 阅读(76) 评论(0) 推荐(0) 编辑
摘要: http://poj.org/problem?id=2739 题意:给1~10000的数字,求他有多少种连续质数分解,连续质数分解就是指连续的某些质数的和,比如2+3+5+7,3+5+7,这样的。 预处理直接暴力。 阅读全文
posted @ 2019-10-23 20:09 Inko 阅读(98) 评论(0) 推荐(0) 编辑
摘要: https://blog.csdn.net/liuxd3000/article/details/17913363 阅读全文
posted @ 2019-10-23 01:26 Inko 阅读(120) 评论(0) 推荐(0) 编辑
摘要: http://poj.org/problem?id=3094 学习fgets的使用,注意fgets是会连换行一起保存的。 cpp include include include include include include include include include include inclu 阅读全文
posted @ 2019-10-22 23:26 Inko 阅读(83) 评论(0) 推荐(0) 编辑
摘要: http://poj.org/problem?id=3006 给一个等差数列,求其中的第n个质数,答案保证不超过1e6。n还特别小?!!! 埃筛之后暴力。 include include include include include include include include include 阅读全文
posted @ 2019-10-22 23:20 Inko 阅读(79) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 ··· 16 下一页