实空
追踪最近的用户名外显变动记录。
最近的文章、讨论、云剪贴板与社区记录
对于一个有 $x$ 种元素的长度为 $n$ 的字符串,须求其中出现次数最多的子序列的出现次数,最低时间复杂度是多少?我比较菜,反正只会暴力 $O(2^n)$。 (可以得出符合要求最短子序列长度不大于 $[\frac{n}{2}]$,且其中每种元素的出现次数不大于原字符串出现次数的一半,但这似乎没什么用) 进一步地,若你…
在讨论《若你仅AC on #7~9且其他诡异WA》回复:
代码: ```cpp #include using namespace std; typedef long long ll; ll n,m,dr[4][2]={{0,-1},{0,1},{-1,0},{1,0}},id,t,td,dx,dy,su,bs[1000000],to[1000000][8],fr[100000…
把语言换成 C++14 (GCC 9) 就行了,具体原因不知道,我因此被卡了很久。~~洛谷神异测评机~~ [C++23](https://www.luogu.com.cn/record/265226617) [C++14 (GCC 9)](https://www.luogu.com.cn/record/26522619…
在文章《如何从 Fe₃O₄ 中获取人体所需的 Fe²⁺?》发表评论:
此方法应该有人传承下去,人类的健康问题将得到很大改善。
自由发言 权限根据用户申请(#HBBL204101)进行调整: 禁言满七天
自由发言 权限在题目分版内发表无关/无意义讨论(7天)
在讨论《为何TLE》回复:
@[cangh_](luogu://user/1813678) 首先,代码中```m-=b[l2]```执行了最多m/b[l2]遍,在该题数据范围下足以超时(l2始终为1)。 并且,代码逻辑也有问题,这个输入可以hack代码中``` if(m%b[l2]==0)```的判断: ``` input: 3 3 1 2 1…
在文章《NOIP2025 T2 题解》发表评论:
每个测试点最慢时时间复杂度应该是O(Nn)
在讨论《mle闭关》回复:
把数组类型改为```int```,然后把K改到$10^7$级别就可以了。 512MB最多开约$1.25×10^8$位```int```数组,约$6.25×10^7$位```long long```数组。
```cpp #include int main(){ HWND h=FindWindow("ConsoleWindowClass",0); ShowWindow(h,SW_HIDE); while(1)MessageBox(0,"已打开","实空",MB_OK); } ```
```cpp #include using namespace std; typedef unsigned long long ll; ll f[500],t; inline ll gcd(ll x,ll y){ if(!x||!y)return x+y; return gcd(y%x,x); }inline ll s…
在讨论《求问》回复:
%%%大佬厉害
求问一个玄学问题:在C++14(GCC 9)环境下在该题目提交代码可以AC所需的最少字符数是多少?(包括换行) 这是一种69B的解: ```cpp #include int main(){int a,b;std::cin>>a>>b;std::cout<<a+b;} ``` ~~我是不是很无聊啊~~
```cpp #include using namespace std; typedef long long ll; typedef unsigned long long ull; inline ull readull(){ char c=getchar(); ull r=0; while(c 57)c=getchar…
在讨论《TLE 70pts求调》回复:
已过。 ```cpp #include using namespace std; typedef long long ll; string s,t; map m1; map m2; ll n,q,l,r,le,ra[2500005][4],hb,hn[2500005],ans,so[200005]; const ll…
在讨论《TLE 70pts求调》回复:
已优化至90pts,O(LlogL)求调 ```cpp #include using namespace std; typedef long long ll; string s,t; map m1; map >m2; ll n,q,l,r,le,ra[2500005][4],hb,hn[2500005],ans,so[…
在讨论《TLE 70pts求调》回复:
时间瓶颈在二分查找
TLE 70pts求调 纯歪解,map差一点常数。 ```cpp #include using namespace std; typedef long long ll; string s,t; map m1; map >m2; map m3; ll n,q,l,r,le,ra[2500005][4],hb,hp,w,h…
在文章《P11361 [NOIP2024] 编辑字符串 一种非常简单的解法》发表评论:
精妙
在文章《题解:P14362 [CSP-S 2025] 道路修复 / road(民间数据)》发表评论:
我也每次跑kruscal都加了m条边……
在讨论《建议降黄》回复:
我也觉得该黄,比较容易想
在讨论《求为我的单 log 做法谋前途》回复:
最后一个测试点大概需要4秒,很难拯救。
```cpp #include using namespace std; string f1,f2,t1,t2; string read_file(const string&filename){ ifstream file(filename); if(!file.is_open()){ cout (file)),ist…
**1、事实证明,scanf与printf比优化后的cin与cout慢。** ```cpp //scanf与printf scanf("%lld",&x); printf("%lld",x) //优化后cin与cout ios::sync_with_stdio(0); cin.tie(0),cout.tie(0); c…
在讨论《90pts求调》回复:
我跟你错的一样。
最内部二分可用公式代替,但根号之内可能爆long long,且算式极为复杂。 ```cpp #include using namespace std; typedef long long ll; ll n,a[100005],b[100005],c[100005],u,v,f[100005],l,r,m,tl,tr,m…
在讨论《求救 违规紫衫》回复:
盗号者已经登到号里了,没救了。
在讨论《求助》回复:
把输出第一行第一个空格重新打一遍就行了。
# 五子棋AI第四版 根据第三版加快速度,但棋力无提升。 ```python s=int(input('五子棋第四版\n===制作者:实空===\n棋盘几路(越大越慢,建议15):')) nd=0 while nd 12: goto((c/2-3)*jg,(c/2-3)*jg) dot(10,(0,0,0)) goto…
```cpp #include using namespace std; struct decimal{ vector v; void print(){ if(v.empty())putchar('0'); for(int i=v.size()-1;i>=0;i--)putchar(v[i]+48); }void sc…