一个小小的常用模板

· · 算法·理论

#include<bits/stdc++.h>
#define ll long long
#define ull unsigned long long
#define pb push_back
#define pf push_front
#define pob pop_back
#define pof pop_front
#define pii pair<int,int>
#define pli pair<ll,int>
#define pll pair<ll,ll>
#define pdi pair<double,int>
#define fi first
#define se second
#define lb lower_bound
#define ub upper_bound
#define fre(x) freopen(x".in","r",stdin),freopen(x".out","w",stdout)
#define frein(x) freopen(x".in","r",stdin)
#define freout(x) freopen(x".out","w",stdout)
using namespace std;
signed solution();
signed main(){solution();system("pause");return 0;}
ll read(){
    ll k=0;bool flag=1;char c=getchar();
    while(!isdigit(c)){if(c=='-')flag=0;c=getchar();}
    while(isdigit(c)){k=(k<<1)+(k<<3)+(c^48);c=getchar();}
    if(flag)return k;else return -k;
}
char readc(){
    char c=getchar();
    while(!isgraph(c))c=getchar();
    return c;
}
string reads(){
    string s="";char c=getchar();
    while(!isgraph(c))c=getchar();
    while(isgraph(c)){s+=c;c=getchar();}
    return s;
}
struct pair_hash{
    template<class T1,class T2>
    size_t operator()(const pair<T1,T2>&pair)const{
        return hash<T1>()(pair.fi)^hash<T2>()(pair.se);
    }
};
struct vector_hash{
    size_t operator()(const vector<int>&v)const{
        hash<int>hasher;size_t sd=0;
        for(int i:v)sd^=hasher(i)+0x9e3779b9+(sd<<6)+(sd>>2);
        return sd;
    }
};

signed solution(){

    return 0;
}