C + + Competition Common header files

Source: Internet
Author: User
Tags bit set mathematical functions cmath

C, traditional C + +

#include <assert.h> set the insertion point
#include <ctype.h> character processing
#include <errno.h> define error codes
#include <float.h> floating point processing
#include <fstream.h> file input/output
#include <iomanip.h> parametric input/output
#include <iostream.h> data stream input/output
#include <limits.h> define a variety of data type-Maximum constants
#include <locale.h> define localization functions
#include <math.h> defining mathematical functions
#include <stdio.h> define input/output functions
#include <stdlib.h> define miscellaneous functions and memory allocation functions
#include <string.h> string processing
#include <strstrea.h> array-based input/output
#include <time.h> define functions about time
#include <wchar.h> wide character processing and input/output
#include <wctype.h> wide character classification

Standard C + +

#include <algorithm> general Algorithms
#include <bitset> bit set container
#include <cctype>
#include <cerrno>
#include <clocale>
#include <cmath>
#include <complex> plural classes
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <ctime>
#include <deque> dual-ended queue container
#include <exception> exception Handling classes
#include <fstream>
#include <functional> define arithmetic functions (instead of operators)
#include <limits>
#include <list> linear list container
#include <map> mapping container
#include <iomanip>
#include <ios> basic input/output support
Pre-declaration for #include <iosfwd> input/output system use
#include <iostream>
#include <istream> Basic input stream
#include <ostream> basic output stream
#include <queue> queue Container
#include <set> collection containers
#include <sstream> string-based streams
#include <stack> stack Container
#include <stdexcept> Standard Exception classes
#include <streambuf> bottom input/output support
#include <string> string Classes
#include <utility> generic template classes
#include <vector> dynamic Array container
#include <cwchar>
#include <cwctype>

C99 Increase

#include <complex.h> complex processing
#include <fenv.h> floating-point environment
#include <inttypes.h> integer format conversion
#include <stdbool.h> boolean environment
#include <stdint.h> integral environment
#include <tgmath.h> generic type math macros

——————————————————————————————————————————

My header file Template:

1#include <iostream>2#include <cstdio>3#include <cstring>4#include <cmath>5#include <algorithm>6#include <queue>7#include <cstdlib>8#include <iomanip>9#include <cassert>Ten#include <climits> One #defineMAXN 1000001 A #defineF (i,j,k) for (int i=j;i<=k;i++) - #defineM (A, B) memset (A,b,sizeof (a)) - #defineFF (i,j,k) for (int i=j;i>=k;i--) the #defineINF 0x7fffffff - using namespacestd; - intRead () { -     intx=0, f=1;CharCh=GetChar (); +      while(ch<'0'|| Ch>'9'){if(ch=='-') f=-1; ch=GetChar ();} -      while(ch>='0'&&ch<='9') {x=x*Ten+ch-'0'; ch=GetChar ();} +     returnx*F; A } at intMain () - { -Std::ios::sync_with_stdio (false);//cout<<setiosflags (ios::fixed) <<setprecision (1) <<y; - #ifdef LOCAL -Freopen ("data.in","R", stdin); -Freopen ("Data.out","W", stdout); in     #endif -    intn,m; to      +}
View Code

C + + Competition Common header files

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.