随笔分类 - Timus
摘要:分析 详见 "这篇非常好的分析" AC代码: C++ include using namespace std; define LL long long LL gcd(LL a, LL b){ return b ? gcd(b, a%b):a; } int main(){ bool ans = tru
阅读全文
摘要:/** *Timus 1014.Product of Digits *Accepted *0.001 252 KB */ #include using namespace std; /// int n; long long solve(int num){ if(num==0) return 10; if(num==1) return 1; long long ans=...
阅读全文
摘要:/* * AC 0.015 404 KB * 枚举每堆石子选或不选 * O(2^20) */ #include #include #include using namespace std; const int maxn = 128e4; int sto[26]; int n, sum=0; int mindif = 1e9; void dfs(int pos, int tol){ ...
阅读全文
摘要:在Timus的题目中,测试数据大小经常表示为“A size of the input stream does not exceed 256 KB.” 那么我们就要清楚txt文件大小的计算方法: 数字、英文字母、英文标点占1B, 中文、中文字符占2B。 那么如题目1001中,测试数据最多有256K /
阅读全文

浙公网安备 33010602011771号