dev万能头文件_超级好用的C++万能头文件
#include包含了目前c++所包含的所有頭文件
對比:
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include using?namespace?std;
int?main(){
return?0;
}
可以直接轉化為:
#include
using?namespace?std;
int?main()
return?0;
}
兼容性問題:
注意,目前POJ還不支持(G++、C++都不支持)。HDU部分支持(G++支持,C++不支持)。
其他國外的oj,還有臺灣的oj都支持,CF,Topcoder也都支持。
當然,其實這是一個偷懶的寫法,但是會降低編譯速度(為何會降低編譯速度,我還不能知道,等到之后學編譯原理再來填坑吧)。
筆試平臺可以使用,方便,VS中并不支持,一般G++ 4.4以上就支持這個頭文件了。當然,私下自己學習就不要去使用了,對你的自主學習一點都沒有好處。
c++11支持這個
po上的源代碼
// C++ includes used for precompiling -*- C++ -*-
// Copyright (C) 2003-2014 Free Software Foundation, Inc. This file is part of the GNU ISO C++ Library. ?This library is free// software; you can redistribute it and/or modify it under the// terms of the GNU General Public License as published by the// Free Software Foundation; either version 3, or (at your option)// any later version.
// This library is distributed in the hope that it will be useful,// but WITHOUT ANY WARRANTY; without even the implied warranty of// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. ?See the// GNU General Public License for more details.
// Under Section 7 of GPL version 3, you are granted additional// permissions described in the GCC Runtime Library Exception, version// 3.1, as published by the Free Software Foundation.
// You should have received a copy of the GNU General Public License and// a copy of the GCC Runtime Library Exception along with this program;// see the files COPYING3 and COPYING.RUNTIME respectively. ?If not, see// .
/** @file stdc++.h
* ?This is an implementation file for a precompiled header.
*/
// 17.4.1.2 Headers
// C#ifndef _GLIBCXX_NO_ASSERT
#include #endif
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#if?__cplusplus >= 201103L
#include
#include
#include
#include
#include
#include
#include
#include
#include #endif
// C++
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#if?__cplusplus >= 201103L
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include #endif
總結
以上是生活随笔為你收集整理的dev万能头文件_超级好用的C++万能头文件的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: c语言的万能头文件,C/C 头文件太难记
- 下一篇: dev万能头文件_【C++】Dev-C+