跳到正文

个人记录

模版

Super26Th_约 1 分钟
原文
文章信息与版本

文章信息

发布
2025年7月16日
收录
2026年2月23日
更新
2026年11月11日
篇幅
约 1 分钟

版本

  1. v1当前

快读

基础版

C++
namespace FastRead{
	struct InRead{
		template<typename T> T read(){
			T x=0;int f=1,ch=getchar();
			while(ch<'0'||ch>'9'){if(ch=='-')f=-1;ch=getchar();}
			while(ch>='0'&&ch<='9'){x=(x<<3)+(x<<1)+(ch^48);ch=getchar();}
			return x*f;
		}
//		template<typename T> void read(T &x){x=read();}
		template<typename T> InRead& operator>>(T &x){return x=read<T>(),(*this);}
	}in;
	struct OutPut{
		template<typename T> void write(T x){
			if(x<0)x=-x,putchar('-');
			if(x>9)write(x/10);
			putchar(x%10+48);
		}
		template<typename T> void write(T x,int c){write(x),putchar(c);}
		template<typename T> OutPut& operator<<(T x){return write(x),(*this);}
	}out;
}using namespace FastRead;
原文