1. #include<bits/stdc++.h>

万能头文件,拼写怎么这么奇怪?

其实,bits表示一个文件夹,stdc++.h是里面的头文件,这表示路径。

搜索这个文件夹,找到后打开。

打开后,发现一堆头文件

  1. // C++ includes used for precompiling -*- C++ -*-
  2.  
  3. // Copyright (C) 2003-2014 Free Software Foundation, Inc.
  4. //
  5. // This file is part of the GNU ISO C++ Library. This library is free
  6. // software; you can redistribute it and/or modify it under the
  7. // terms of the GNU General Public License as published by the
  8. // Free Software Foundation; either version 3, or (at your option)
  9. // any later version.
  10.  
  11. // This library is distributed in the hope that it will be useful,
  12. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  13. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  14. // GNU General Public License for more details.
  15.  
  16. // Under Section 7 of GPL version 3, you are granted additional
  17. // permissions described in the GCC Runtime Library Exception, version
  18. // 3.1, as published by the Free Software Foundation.
  19.  
  20. // You should have received a copy of the GNU General Public License and
  21. // a copy of the GCC Runtime Library Exception along with this program;
  22. // see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
  23. // <http://www.gnu.org/licenses/>.
  24.  
  25. /** @file stdc++.h
  26. * This is an implementation file for a precompiled header.
  27. */
  28.  
  29. // 17.4.1.2 Headers
  30.  
  31. // C
  32. #ifndef _GLIBCXX_NO_ASSERT
  33. #include <cassert>
  34. #endif
  35. #include <cctype>
  36. #include <cerrno>
  37. #include <cfloat>
  38. #include <ciso646>
  39. #include <climits>
  40. #include <clocale>
  41. #include <cmath>
  42. #include <csetjmp>
  43. #include <csignal>
  44. #include <cstdarg>
  45. #include <cstddef>
  46. #include <cstdio>
  47. #include <cstdlib>
  48. #include <cstring>
  49. #include <ctime>
  50.  
  51. #if __cplusplus >= 201103L
  52. #include <ccomplex>
  53. #include <cfenv>
  54. #include <cinttypes>
  55. #include <cstdalign>
  56. #include <cstdbool>
  57. #include <cstdint>
  58. #include <ctgmath>
  59. #include <cwchar>
  60. #include <cwctype>
  61. #endif
  62.  
  63. // C++
  64. #include <algorithm>
  65. #include <bitset>
  66. #include <complex>
  67. #include <deque>
  68. #include <exception>
  69. #include <fstream>
  70. #include <functional>
  71. #include <iomanip>
  72. #include <ios>
  73. #include <iosfwd>
  74. #include <iostream>
  75. #include <istream>
  76. #include <iterator>
  77. #include <limits>
  78. #include <list>
  79. #include <locale>
  80. #include <map>
  81. #include <memory>
  82. #include <new>
  83. #include <numeric>
  84. #include <ostream>
  85. #include <queue>
  86. #include <set>
  87. #include <sstream>
  88. #include <stack>
  89. #include <stdexcept>
  90. #include <streambuf>
  91. #include <string>
  92. #include <typeinfo>
  93. #include <utility>
  94. #include <valarray>
  95. #include <vector>
  96.  
  97. #if __cplusplus >= 201103L
  98. #include <array>
  99. #include <atomic>
  100. #include <chrono>
  101. #include <condition_variable>
  102. #include <forward_list>
  103. #include <future>
  104. #include <initializer_list>
  105. #include <mutex>
  106. #include <random>
  107. #include <ratio>
  108. #include <regex>
  109. #include <scoped_allocator>
  110. #include <system_error>
  111. #include <thread>
  112. #include <tuple>
  113. #include <typeindex>
  114. #include <type_traits>
  115. #include <unordered_map>
  116. #include <unordered_set>
  117. #endif

以后就明白,bits/stdc++.h是啥了!

PS:如果你在用Mac,请参阅这篇文章(点击前往)

C++万能头文件的秘密的更多相关文章

  1. Opencv各个版本的万能头文件

    每次下载opencv的新版本时,都需要重新写头文件,更改链接库配置,很麻烦有木有?下面这个头文件是我在别人的代码中淘出来的,很不错,与大家分享~(具体作者忘记了,不好意思啊) 作者很巧妙地利用Open ...

  2. 万能头文件#include

    #include<bits/stdc++.h>包含了目前c++所包含的所有头文件!!!! 测试结果POJ不支持HDU,NYOJ支持

  3. Visual Studio 中使用万能头文件 #include <bits/stdc++.h>

    最近开始使用VS,之前用的DEV C++软件可直接使用 #include <bits/stdc++.h>  ,但VS中并没有,为了使用方便,可直接在VS中添加此头文件,方法如下: 1.在安 ...

  4. 万能头文件#include <bits/stdc++.h>

    最近在做题的时候看到别人的题解发现别人都用这个 突然之间打开新世界的大门 去百度之后才知道#include <bits/stdc++.h>包含了目前所有的c++头文件 也就是说只要用#in ...

  5. 超级好用的C++万能头文件

    #include<bits/stdc++.h>包含了目前c++所包含的所有头文件 对比: #include <iostream> #include <cstdio> ...

  6. 万能头文件#include<bits/stdc++.h>

    最近在打cf时赛后翻阅别人的代码总是会发现一个陌生而奇怪的头文件#include<bits/stdc++.h> 奇怪之处就在于基本上所有的代码只要用了这个头文件就不再写其他头文件了. 百度 ...

  7. C++万能头文件<bits/stdc++.h>的内容与优缺点

    最近发现了一个C++的头文件bits/stdc++.h,听说这是一个几乎包含了所有C++库函数的头文件,就想更深入的了解一下,下面是头文件内容 // C++ includes used for pre ...

  8. gcc中C++一个特别的头文件

    今天在一段程序中看到这样一个很奇怪的语句: #include<bits/stdc++.h> 博主查了之后发现业界称其万能头文件,这个头文件包含了如下等头文件,几乎包含了所有的C++标准库头 ...

  9. ACM竞赛常用头文件模板-备忘

    备忘. #include<iostream> #include<cstdio> #include<cstring> #include<algorithm> ...

随机推荐

  1. PAT 2-13. 两个有序序列的中位数(25)

    题目链接:http://www.patest.cn/contests/ds/2-13 解题思路及代码如下: /* 解题思路: 分别求出序列A 和B 的中位数,设为a 和b,求序列A 和B 的中位数过程 ...

  2. 免费API接口记录

    用来记录一些无次数限制的免费API接口,主要是聚合数据上和API Store上的一些,还有一些其他的. 手机号码归属地API接口: https://www.juhe.cn/docs/api/id/11 ...

  3. 第1章 Hive入门

    第1章 Hive入门 1.1 什么是Hive Hive:由Facebook开源用于解决海量结构化日志的数据统计. Hive是基于Hadoop的一个数据仓库工具,可以将结构化的数据文件映射为一张表,并提 ...

  4. Hello,Vue

    Vue版本 Vue完整版 有编译器compiler,体积大功能多,可以直接把html字符串变成DOM节点 视图,此处为html字符串,写在index.html里或者写在new Vue构造选项templ ...

  5. SPSSAU数据分析思维培养系列4:数据可视化篇

    本文章为SPSSAU数据分析思维培养的第4期文章. 前3期内容分别讲述数据思维,分析方法和分析思路.本文讲述如何快速使用SPSSAU进行高质量作图,以及如何选择使用正确的图形. 本文分别从五个角度进行 ...

  6. ID3\C4.5\CART

    目录 树模型原理 ID3 C4.5 CART 分类树 回归树 树创建 ID3.C4.5 多叉树 CART分类树(二叉) CART回归树 ID3 C4.5 CART 特征选择 信息增益 信息增益比 基尼 ...

  7. 字段在class文件中的存在形式——FieldInfo

    每个字段(Field)都有field_info结构所定义,一个class文件中,不会有两个字段同时具有相同的名字和描述符 name_index:值为一个整数(常量池表中的有效索引),例如name_in ...

  8. css面试题汇总 (持续更新)

    前言:这篇随笔是为了准备后面的面试而整理的,网上各种面试题太多了,但是我感觉很多太偏了,而且实际开发过程中并不会遇到,因此这里我整理一些比较常用的,或者是相对比较重要的知识点,每个知识点都会由浅入深, ...

  9. python爬虫--看看虎牙女主播中谁颜值最高

    目录 爬虫 百度人脸识别接口 效果演示 很多人学习python,不知道从何学起.很多人学习python,掌握了基本语法过后,不知道在哪里寻找案例上手.很多已经做案例的人,却不知道如何去学习更加高深的知 ...

  10. Bitmap转ImageSource

    bitmap to bytes Bitmap b = new Bitmap( "test.bmp "); MemoryStream ms = new MemoryStream(); ...