快读

这是一个刷数量的博客,大佬勿入。


前面写过一个有关inline的博客,但是并没有什么用,但是这里就体现出来了。

inline int read()
{
    int x=0,f=1;char ch=getchar();
    while (!isdigit(ch)){if (ch=='-') f=-1;ch=getchar();}
    while (isdigit(ch)){x=x*10+ch-48;ch=getchar();}
    return x*f;
}

inline本身没有什么用但是在加快速度上经常见到。

原文地址:https://www.cnblogs.com/lizhengde/p/13246020.html