摘要:
# include <bits/stdc++.h>#define MAX_L 2005 //最大长度,可以修改using namespace std; class bign{public: int len, s[MAX_L];//数的长度,记录数组//构造函数 bign(); bign(const 阅读全文
posted @ 2022-02-26 23:13
fengzlj
阅读(31)
评论(0)
推荐(0)
摘要:
//Pollard_Rho && Miller_Rabin class类//跑的快的时候可以到1.01s #pragma GCC optimize("Ofast")#include<bits/stdc++.h>typedef long long LL;typedef long double LD; 阅读全文
posted @ 2022-02-26 23:12
fengzlj
阅读(72)
评论(0)
推荐(0)
摘要:
N次剩余 //【题意】 给定newx,k,m,方程(x^k)%m=newx,求在模m意义下的所有解x//【限制】 0 <= newx,m,k <= 1.5*10^15; m是素数# include <bits/stdc++.h>using namespace std;# define LL __in 阅读全文
posted @ 2022-02-26 23:11
fengzlj
阅读(169)
评论(0)
推荐(0)
摘要:
学长们又在vj上拉比赛了,菜鸡的我补一补学长们说的水题。QAQ 第十届山东省ACM省赛 A - Calandar 有点类似于2050的一道题,就是因为是以5为周期的,所以年数和月数都对于最后的结果没有影响,有可以想到定义的是一个月有30天,所以每个月的同一天的星期数是一样的,可以搞一个数组存下一个月 阅读全文
posted @ 2022-02-26 23:11
fengzlj
阅读(63)
评论(0)
推荐(0)
摘要:
持续更新~~直到省赛 #8 The 14-th BIT Campus Programming Contest()GYM A - 两只脑斧 # include <bits/stdc++.h> using namespace std; int main() { int n; string a; char 阅读全文
posted @ 2022-02-26 23:10
fengzlj
阅读(44)
评论(0)
推荐(0)
摘要:
BSGS //unordered_map<LL,LL>m;// 300ms# include <bits/stdc++.h>using namespace std;typedef long long LL;unordered_map<LL,LL>m;LL quick_pow(LL a,LL b,L 阅读全文
posted @ 2022-02-26 23:10
fengzlj
阅读(25)
评论(0)
推荐(0)
摘要:
Lucas //求c(n,m)%p 其中p是质数 # include <bits/stdc++.h>using namespace std;typedef long long LL;LL mulit(LL a,LL b,LL mod){ LL res=0; while(b){ if(b&1) re 阅读全文
posted @ 2022-02-26 23:10
fengzlj
阅读(53)
评论(0)
推荐(0)
摘要:
#include <bits/stdc++.h>using namespace std;inline __int128 read(){ __int128 x=0,f=1; char ch=getchar(); while(ch<'0'||ch>'9'){ if(ch=='-') f=-1; ch=g 阅读全文
posted @ 2022-02-26 23:09
fengzlj
阅读(193)
评论(0)
推荐(0)
摘要:
今天打完PTA了,还是太菜了。。。 把以前整理的关于PTA的心得发一下出来吧,希望以后有需要的朋友能够方便一点吧。 L1-035 情人节 字符串比较可以直接用等号,也可以用strcmp函数(==0为相同) 字符比较则也可以用等号 # include <bits/stdc++.h> using nam 阅读全文
posted @ 2022-02-26 23:08
fengzlj
阅读(247)
评论(0)
推荐(0)
摘要:
最长上升子序列 NlogN hdu 1950 # include <bits/stdc++.h>using namespace std;const int MAXN=2e6+100;int a[MAXN],dp[MAXN];//vector<int> ans;int main(){ int T; 阅读全文
posted @ 2022-02-26 23:08
fengzlj
阅读(54)
评论(0)
推荐(0)
浙公网安备 33010602011771号