{ “模板”: { “prefix”: “temp”, // 自定义短触发词 “body”: [ “#include <bits/stdc++.h>”, “#define ll long long”, “#define pll pair<ll,ll>”, “#define fs first”, “#define sc second”, “#define all(v) v.begin(),v.end()”, “#define pb push_back”, “#define ppb pop_back”, “#define getc getchar”, “#define putc putchar”, “using namespace std;”, “const ll N=;”, “int main()”, ”{”, ” ios::sync_with_stdio(0);”, ” cin.tie(0);”, ” {1}", " return 0;", "}" // {1}表示光标初始位置 ] }, “计数模板”: { “prefix”: “counting”, // 自定义短触发词 “body”: [ “#include <bits/stdc++.h>”, “#define ll long long”, “#define pll pair<ll,ll>”, “#define fs first”, “#define sc second”, “#define all(v) v.begin(),v.end()”, “#define pb push_back”, “#define ppb pop_back”, “#define getc getchar”, “#define putc putchar”, “using namespace std;”, “const ll N=,MOD=;”, “inline ll mod(ll x){return x%MOD;}”, “inline void ADD(ll &x,ll y){x=mod(x+y);}”, “inline ll qpow(ll bs,ll k)”, ”{”, ” ll ret=1;”, ” while(k)”, ” {”, ” if(k&1) ret=mod(retbs);”, ” bs=mod(bsbs);”, ” k>>=1;”, ” }”, ” return ret;”, ”}”, “ll inv[N],fac[N],ifac[N];”, “inline ll C(ll x,ll y)”, ”{”, ” if(x<0||y<0||x<y) return 0;”, ” return mod(fac[x]*mod(ifac[x-y]ifac[y]));”, ”}”, “int main()”, ”{”, ” ios::sync_with_stdio(0);”, ” cin.tie(0);”, ” ll nv=;”, ” inv[0]=inv[1]=1;”, ” for(ll i=2;i<=nv;i++)”, ” inv[i]=MOD-mod(MOD/iinv[MOD%i]);”, ” fac[0]=ifac[0]=1;”, ” for(ll i=1;i<=nv;i++)”, ” {”, ” fac[i]=mod(fac[i-1]*i);”, ” ifac[i]=mod(ifac[i-1]inv[i]);”, ” }”, ” {1}", " return 0;", "}" // {1}表示光标初始位置 ] }, “DP模板”: { “prefix”: “DP”, // 自定义短触发词 “body”: [ “#include <bits/stdc++.h>”, “#define ll long long”, “#define pll pair<ll,ll>”, “#define fs first”, “#define sc second”, “#define all(v) v.begin(),v.end()”, “#define pb push_back”, “#define ppb pop_back”, “#define getc getchar”, “#define putc putchar”, “using namespace std;”, “const ll N=,MOD=;”, “inline ll mod(ll x){return x%MOD;}”, “inline void ADD(ll &x,ll y){x=mod(x+y);}”, “inline void MIN(auto &x,auto y){x=x<y?x:y;}”, “inline void MAX(auto &x,auto y){x=x>y?x:y;}”, “int main()”, ”{”, ” ios::sync_with_stdio(0);”, ” cin.tie(0);”, ” {1}", " return 0;", "}" // {1}表示光标初始位置 ] }, “造数据模板”: { “prefix”: “data”, // 自定义短触发词 “body”: [ “#include <bits/stdc++.h>”, “#include <sys/time.h>”, “#define ll long long”, “#define pll pair<ll,ll>”, “#define fs first”, “#define sc second”, “#define all(v) v.begin(),v.end()”, “#define pb push_back”, “#define ppb pop_back”, “#define getc getchar”, “#define putc putchar”, “using namespace std;”, “int main()”, ”{”, ” ios::sync_with_stdio(0);”, ” cin.tie(0);”, ” timeval tm;”, ” gettimeofday(&tm,0);”, ” mt19937 rd(tm.tv_sec(ll)1e6+tm.tv_usec);”, ” {1}", " return 0;", "}" // {1}表示光标初始位置 ] }, “checker-windows”: { “prefix”: “checkerW”, // 自定义短触发词 “body”: [ “#include <bits/stdc++.h>”, “#define ll long long”, “#define pll pair<ll,ll>”, “#define fs first”, “#define sc second”, “#define all(v) v.begin(),v.end()”, “#define pb push_back”, “#define ppb pop_back”, “#define getc getchar”, “#define putc putchar”, “using namespace std;”, “int main()”, ”{”, ” ll tot=0;”, ” while(1)”, ” {”, ” cout<<++tot<<‘\n’;”, ” system(“data.exe>data.in”);”, ” system(“force.exe<data.in>data.out”);”, ” system(“tmp.exe<data.in>tmp.out”);”, ” if(system(“fc tmp.out data.out”))”, ” break;”, ” }”, ” return 0;”, ”}” // {1}表示光标初始位置 ] }, "checker-linux": { "prefix": "checkerL", // 自定义短触发词 "body": [ "#include <bits/stdc++.h>", "#define ll long long", "#define pll pair<ll,ll>", "#define fs first", "#define sc second", "#define all(v) v.begin(),v.end()", "#define pb push_back", "#define ppb pop_back", "#define getc getchar", "#define putc putchar", "using namespace std;", "int main()", "{", " ll tot=0;", " system(\"g++ data.cpp -o data -std=c++14 -O2\");", " system(\"g++ force.cpp -o force -std=c++14 -O2\");", " system(\"g++ .cpp -o -std=c++14 -O2\");", " while(1)", " {", " cout<<++tot<<'\\n';", " system(\"./data\");", " system(\"./force\");", " system(\"./\");", " if(system(\"diff .out .ans -Z -B -s\"))", " break;", " }", " return 0;", "}" // {1}表示光标初始位置 ] }, “debug”: { “prefix”: “debug”, // 自定义短触发词 “body”: [ “#ifndef ONLINE_JUDGE”, ” freopen(“data.in”,“r”,stdin);”, ” freopen(“tmp.out”,“w”,stdout);”, “#endif” // {1}表示光标初始位置 ] }, "FastIO": { "prefix": "fastio", // 自定义短触发词 "body": [ "#pragma GCC optimize(\"Ofast,no-stack-protector\")", "#pragma GCC target(\"sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native\")", "namespace Fastio {", "const int L = 1 << 20;", "inline char gc() {", " static char buf[L], *l = buf, *r = buf;", " if (l == r)", " r = (l = buf) + fread(buf, 1, L, stdin);", " return (l == r) ? EOF : *l++;", "}", "char obuf[L], *p = obuf;", "inline void pc(char c) {", " if (p == obuf + L)", " fwrite(obuf, 1, L, stdout), p = obuf;", " *p++ = c;", "}", "inline void flush() { fwrite(obuf, 1, p - obuf, stdout); }", "struct Reader {", " template <typename T>", " inline Reader& operator>>(T& x) {", " x = 0;", " char c = gc();", " while (!isdigit(c)) c = gc();", " while (isdigit(c)) x = 10 * x + (c - '0'), c = gc();", " return *this;", " }", " Reader() {}", "} cin;", "struct Writer {", " template <typename T>", " inline Writer& operator<<(T x) {", " static short tp = 0, s[40];", " do", " s[++tp] = x % 10, x /= 10;", " while (x);", " while (tp) pc(s[tp--] + '0');", " return *this;", " }", " inline Writer& operator<<(const char* s) {", " int i = 0;", " while (s[i]) pc(s[i++]);", " return *this;", " }", " inline Writer& operator<<(char c) {", " pc(c);", " return *this;", " }", " Writer() {}", " ~Writer() { flush(); }", "} cout;", "#define cin Fastio::cin", "#define cout Fastio::cout", "}" // {1}表示光标初始位置 ] } }