//STATUS:C++_AC_500MS_1012KB#include <functional>#include <algorithm>#include <iostream>//#include <ext/rope>#include <fstream>#include <sstream>#include <iomanip>#include <numeric>#include <cstring>#include <cassert>#include <cstdio>#include <string>#include <vector>#include <bitset>#include <queue>#include <stack>#include <cmath>#include <ctime>#include <list>#include <set>#include <map>using namespace std;//using namespace __gnu_cxx;//define#define pii pair<int,int>#define mem(a,b) memset(a,b,sizeof(a))#define lson l,mid,rt<<1#define rson mid+1,r,rt<<1|1#define PI acos(-1.0)//typedeftypedef __int64 LL;typedef unsigned __int64 ULL;//constconst int N=100010;const int INF=0x3f3f3f3f;const int MOD=100000,STA=8000010;const LL LNF=1LL<<60;const double EPS=1e-8;const double OO=1e15;const int dx[4]={-1,0,1,0};const int dy[4]={0,1,0,-1};const int day[13]={0,31,28,31,30,31,30,31,31,30,31,30,31};//Daily Use ...inline int sign(double x){return (x>EPS)-(x<-EPS);}template<class T> T gcd(T a,T b){return b?gcd(b,a%b):a;}template<class T> T lcm(T a,T b){return a/gcd(a,b)*b;}template<class T> inline T lcm(T a,T b,T d){return a/d*b;}template<class T> inline T Min(T a,T b){return a<b?a:b;}template<class T> inline T Max(T a,T b){return a>b?a:b;}template<class T> inline T Min(T a,T b,T c){return min(min(a, b),c);}template<class T> inline T Max(T a,T b,T c){return max(max(a, b),c);}template<class T> inline T Min(T a,T b,T c,T d){return min(min(a, b),min(c,d));}template<class T> inline T Max(T a,T b,T c,T d){return max(max(a, b),max(c,d));}//End
另一个头文件
包含快速输入函数
1 #include <algorithm> 2 #include <iostream> 3 #include <fstream> 4 #include <sstream> 5 #include <iomanip> 6 7 #include <map> 8 #include <set> 9 #include <list> 10 #include <stack> 11 #include <queue> 12 #include <deque> 13 #include <vector> 14 #include <string> 15 #include <bitset> 16 #include <complex> 17 #include <memory> 18 #include <numeric> 19 20 #include <stdio.h> 21 #include <stdlib.h> 22 #include <string.h> 23 #include <math.h> 24 #include <time.h> 25 #include <ctype.h> 26 #include <locale.h> 27 28 using namespace std ; 29 30 const int inf=0x7f7f7f7f ; 31 const int INF=0x7fffffff ; 32 const double eps=1e-8 ; 33 const double pi=acos(-1.0); 34 35 template<class Type>bool scanf(Type&val) 36 { 37 char cin=getchar(); 38 if(cin==EOF)return false ; 39 else 40 { 41 val=0 ; 42 while('0'>cin||cin>'9')if((cin=getchar())==EOF)return false ; 43 while('0'<=cin&&cin<='9') 44 { 45 val*=10,val+=(cin-'0'); 46 if((cin=getchar())==EOF)return false ; 47 } 48 return true ; 49 } 50 } 51 52 #define _gret(a,b) ((a)-(b)>eps) 53 #define _less(a,b) ((b)-(a)>eps) 54 #define _equl(a,b) (fabs((a)-(b))<eps) 55 #define _sign(val) (_gret(val,0.0)?1:(_equl(val,0.0)?0:-1)) 56 57 #define _lowbit(val) ((val)&(-val)) 58 #define _max(a,b) (_gret(a,b)?(a):(b)) 59 #define _min(a,b) (_less(a,b)?(a):(b)) 60 #define _for(i,a,b) for(int i=(a);i<=(b);i++) 61 #define _clr(a,val,n) memset(a,val,sizeof(a[0])*(n)) View Code
转载于:https://www.cnblogs.com/Skyxj/p/3201629.html
相关资源:MC9S12XS128控制12864液晶头文件