代码如下
struct _Scan{
_Scan(){setvbuf(stdin,(char*)calloc(0x100000,1),_IOFBF,0x100000);}
#define deff(T,n) _Scan& operator>>(T&x){scanf("%"#n,&x);return *this;}
deff(int,i);deff(long long,lli);
} cinf;
也有
deff(double,lf);deff(char,c);deff(long double,Lf);