rt,这东西在OI中用处大吗
namespace IO {
#define ll long long
const int MAX = 1<<23;
char buf[MAX],*p1=buf,*p2=buf;
char obuf[MAX],*o=obuf;
#define gc() (p1==p2&&(p2=(p1=buf)+fread(buf,1,1<<21,stdin),p1==p2)?EOF:*p1++)
template<typename T>
inline T read() {
T res = 0;
int f = 1;
char c = gc();
while(!isdigit(c)) {
if(c=='-') f=-1;
c=gc();
}
while(isdigit(c)) {
res = (res<<3)+(res<<1)+(c^48);
c=gc();
}
return res*f;
}
void print(ll x) {
if(x > 9) print(x/10);
*o++=(x%10)+'0';
}
void pc(char c) {
*o++=c;
}
void write(ll x,char end) {
if(x<0) pc('-');
print(abs(x));
pc(end);
}
void flush() {
fwrite(obuf,o-obuf,1,stdout);
o = obuf;
}
#undef ll
}
还有就是为什么有时候用了template的快读会TLE