|
|
<!DOCTYPE html>
|
|
|
<html lang="en" dir="ltr">
|
|
|
<head>
|
|
|
<meta name="generator" content="Hugo 0.126.1">
|
|
|
<meta charset="UTF-8">
|
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
|
<meta name="description" content="C++ Annotations Version 12.4.0 # Frank B. BrokkenUniversity of Groningen, PO Box 407,9700 AK GroningenThe NetherlandsISBN 90 367 0470 71994-2023 # This document is intended for knowledgeable users of C (or any other language using a C-like grammar, like Perl or Java) who would like to know more about, or make the transition to, C++. This document is the main textbook for Frank’s C++ programming courses, which are yearly organized at the University of Groningen.">
|
|
|
<meta name="theme-color" media="(prefers-color-scheme: light)" content="#ffffff">
|
|
|
<meta name="theme-color" media="(prefers-color-scheme: dark)" content="#343a40">
|
|
|
<meta name="color-scheme" content="light dark"><meta property="og:url" content="https://doc.cyub.vip/cpp/">
|
|
|
<meta property="og:site_name" content="C++ Annotations Version 12.4.0">
|
|
|
<meta property="og:title" content="Introduction">
|
|
|
<meta property="og:description" content="C++ Annotations Version 12.4.0 # Frank B. BrokkenUniversity of Groningen, PO Box 407,9700 AK GroningenThe NetherlandsISBN 90 367 0470 71994-2023 # This document is intended for knowledgeable users of C (or any other language using a C-like grammar, like Perl or Java) who would like to know more about, or make the transition to, C++. This document is the main textbook for Frank’s C++ programming courses, which are yearly organized at the University of Groningen.">
|
|
|
<meta property="og:locale" content="en">
|
|
|
<meta property="og:type" content="website">
|
|
|
<title>Introduction | C++ Annotations Version 12.4.0</title>
|
|
|
<link rel="manifest" href="/cpp/manifest.json">
|
|
|
<link rel="icon" href="/cpp/favicon.png" >
|
|
|
<link rel="canonical" href="https://doc.cyub.vip/cpp/">
|
|
|
<link rel="alternate" hreflang="zh" href="https://doc.cyub.vip/cpp/zh/" title="介绍">
|
|
|
<link rel="stylesheet" href="/cpp/book.min.309b7ed028807cdb68d8d61e26d609f48369c098dbf5e4d8c0dcf4cdf49feafc.css" integrity="sha256-MJt+0CiAfNto2NYeJtYJ9INpwJjb9eTYwNz0zfSf6vw=" crossorigin="anonymous">
|
|
|
<script defer src="/cpp/fuse.min.js"></script>
|
|
|
<script defer src="/cpp/en.search.min.96d87afe14f4404fb82eb23166af34b971841affca153da6e6aee977701013ac.js" integrity="sha256-lth6/hT0QE+4LrIxZq80uXGEGv/KFT2m5q7pd3AQE6w=" crossorigin="anonymous"></script>
|
|
|
|
|
|
<script defer src="/cpp/sw.min.5d1fdbd1fdf1d81d76c1e5a2529d146b38922120c27ebed041d7584fa87ce6df.js" integrity="sha256-XR/b0f3x2B12weWiUp0UaziSISDCfr7QQddYT6h85t8=" crossorigin="anonymous"></script>
|
|
|
|
|
|
|
|
|
|
|
|
<link rel="alternate" type="application/rss+xml" href="https://doc.cyub.vip/cpp/index.xml" title="C++ Annotations Version 12.4.0" />
|
|
|
<!--
|
|
|
Made with Book Theme
|
|
|
https://github.com/alex-shpak/hugo-book
|
|
|
-->
|
|
|
|
|
|
</head>
|
|
|
<body dir="ltr">
|
|
|
<input type="checkbox" class="hidden toggle" id="menu-control" />
|
|
|
<input type="checkbox" class="hidden toggle" id="toc-control" />
|
|
|
<main class="container flex">
|
|
|
<aside class="book-menu">
|
|
|
<div class="book-menu-content">
|
|
|
|
|
|
<nav>
|
|
|
<h2 class="book-brand">
|
|
|
<a class="flex align-center" href="/cpp/"><span>C++ Annotations Version 12.4.0</span>
|
|
|
</a>
|
|
|
</h2>
|
|
|
|
|
|
|
|
|
<div class="book-search hidden">
|
|
|
<input type="text" id="book-search-input" placeholder="Search" aria-label="Search" maxlength="64" data-hotkeys="s/" />
|
|
|
<div class="book-search-spinner hidden"></div>
|
|
|
<ul id="book-search-results"></ul>
|
|
|
</div>
|
|
|
<script>document.querySelector(".book-search").classList.remove("hidden")</script>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<ul class="book-languages">
|
|
|
<li>
|
|
|
<input type="checkbox" id="languages" class="toggle" />
|
|
|
<label for="languages" class="flex justify-between">
|
|
|
<a role="button" class="flex align-center">
|
|
|
<img src="/cpp/svg/translate.svg" class="book-icon" alt="Languages" />
|
|
|
English
|
|
|
</a>
|
|
|
</label>
|
|
|
|
|
|
<ul>
|
|
|
|
|
|
<li>
|
|
|
<a href="https://doc.cyub.vip/cpp/zh/">
|
|
|
Chinese
|
|
|
</a>
|
|
|
</li>
|
|
|
|
|
|
</ul>
|
|
|
</li>
|
|
|
</ul>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<ul>
|
|
|
<li>
|
|
|
<a href="/cpp/docs/Overview/">1. Overview</a></li>
|
|
|
<li><strong>2. C++ Intro</strong></li>
|
|
|
<li>
|
|
|
<a href="/cpp/docs/A-First-Impression/">3. A First Impression</a></li>
|
|
|
<li>
|
|
|
<a href="/cpp/docs/Name-Spaces/">4. Name Spaces</a></li>
|
|
|
<li><strong>5. Strings</strong></li>
|
|
|
<li>
|
|
|
<a href="/cpp/docs/IOStreams/">6. IOStreams</a></li>
|
|
|
<li><strong>7. Classes</strong></li>
|
|
|
<li>
|
|
|
<a href="/cpp/docs/Static-Data-And-Functions/">8. Static Data And Functions</a></li>
|
|
|
<li><strong>9. Memory Management</strong></li>
|
|
|
<li><strong>10. Exceptions</strong></li>
|
|
|
<li><strong>11. Operator Overloading</strong></li>
|
|
|
<li><strong>12. Abstract Containers</strong></li>
|
|
|
<li><strong>13. Inheritance</strong></li>
|
|
|
<li><strong>14. Polymorphism</strong></li>
|
|
|
<li>
|
|
|
<a href="/cpp/docs/Friends/">15. Friends</a></li>
|
|
|
<li><strong>16. Pointers to Members</strong></li>
|
|
|
<li><strong>17. Nested Classes</strong></li>
|
|
|
<li><strong>18. Standard Template Library</strong></li>
|
|
|
<li><strong>19. Generic Algorithms</strong></li>
|
|
|
<li><strong>20. Multi Threading</strong></li>
|
|
|
<li><strong>21. Function Templates</strong></li>
|
|
|
<li><strong>22. Class Templates</strong></li>
|
|
|
<li><strong>23. Advanced Template Use</strong></li>
|
|
|
<li><strong>24. Coroutines</strong></li>
|
|
|
<li><strong>25. Examples</strong></li>
|
|
|
</ul>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</nav>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<script>(function(){var e=document.querySelector("aside .book-menu-content");addEventListener("beforeunload",function(){localStorage.setItem("menu.scrollTop",e.scrollTop)}),e.scrollTop=localStorage.getItem("menu.scrollTop")})()</script>
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
</aside>
|
|
|
|
|
|
<div class="book-page">
|
|
|
<header class="book-header">
|
|
|
|
|
|
<div class="flex align-center justify-between">
|
|
|
<label for="menu-control">
|
|
|
<img src="/cpp/svg/menu.svg" class="book-icon" alt="Menu" />
|
|
|
</label>
|
|
|
|
|
|
<strong>Introduction</strong>
|
|
|
|
|
|
<label for="toc-control">
|
|
|
|
|
|
</label>
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</header>
|
|
|
|
|
|
|
|
|
|
|
|
<article class="markdown book-article"><h1 id="c-annotations-version-1240">
|
|
|
C++ Annotations Version 12.4.0
|
|
|
<a class="anchor" href="#c-annotations-version-1240">#</a>
|
|
|
</h1>
|
|
|
<div class="book-columns flex flex-wrap">
|
|
|
|
|
|
<div class="flex-even markdown-inner">
|
|
|
<!-- begin columns block -->
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<div class="flex-even markdown-inner">
|
|
|
<!-- magic separator, between columns -->
|
|
|
<h2 id="frank-b-brokkenbruniversity-of-groningen-brpo-box-407br9700-ak-groningenbrthe-netherlandsbrisbn-90-367-0470-7brbr1994-2023">
|
|
|
Frank B. Brokken<br/>University of Groningen, <br/>PO Box 407,<br/>9700 AK Groningen<br/>The Netherlands<br/>ISBN 90 367 0470 7<br/><br/>1994-2023
|
|
|
<a class="anchor" href="#frank-b-brokkenbruniversity-of-groningen-brpo-box-407br9700-ak-groningenbrthe-netherlandsbrisbn-90-367-0470-7brbr1994-2023">#</a>
|
|
|
</h2>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<div class="flex-even markdown-inner">
|
|
|
<!-- magic separator, between columns -->
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<p>This document is intended for knowledgeable users of C (or any other language using a C-like grammar, like Perl or Java) who would like to know more about, or make the transition to, C++. This document is the main textbook for Frank’s C++ programming courses, which are yearly organized at the University of Groningen. The C++ Annotations do not cover all aspects of C++, though. In particular, C++’s basic grammar is not covered when equal to C’s grammar. Any basic book on C may be consulted to refresh that part of C++’s grammar.</p>
|
|
|
<p>If you want a hard-copy version of the C++ Annotations: printable versions are available in zip-archives containing files in postscript, pdf and other formats at
|
|
|
|
|
|
<a href="https://gitlab.com/fbb-git/cppannotations-zip">https://gitlab.com/fbb-git/cppannotations-zip</a>
|
|
|
Pages of files having names starting with cplusplus are in A4 paper size, pages of files having names starting with cplusplusus are in the US legal paper size. The C++ Annotations are also available as a Kindle book.</p>
|
|
|
<p>The latest version of the C++ Annotations in html-format can be browsed at:
|
|
|
<a href="https://fbb-git.gitlab.io/cppannotations/">https://fbb-git.gitlab.io/cppannotations/</a> and/or at
|
|
|
<a href="http://www.icce.rug.nl/documents/">http://www.icce.rug.nl/documents/</a></p>
|
|
|
<p>Don’t hesitate to send in feedback: send an e-mail if you like the C++ Annotations; if you think that important material was omitted; if you find errors or typos in the text or the code examples; or if you just feel like e-mailing. Send your e-mail to Frank B. Brokken.</p>
|
|
|
<p>Please state the document version you’re referring to, as found in the title (in this document: 12.4.0) and please state chapter and paragraph name or number you’re referring to.</p>
|
|
|
<p>All received mail is processed conscientiously, and received suggestions for improvements are usually processed by the time a new version of the Annotations is released. Except for the incidental case I will normally not acknowledge the receipt of suggestions for improvements. Please don’t interpret this as me not appreciating your efforts.</p>
|
|
|
</article>
|
|
|
|
|
|
|
|
|
|
|
|
<footer class="book-footer">
|
|
|
|
|
|
<div class="flex flex-wrap justify-between">
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
<script>(function(){function e(e){const t=window.getSelection(),n=document.createRange();n.selectNodeContents(e),t.removeAllRanges(),t.addRange(n)}document.querySelectorAll("pre code").forEach(t=>{t.addEventListener("click",function(){if(window.getSelection().toString())return;e(t.parentElement),navigator.clipboard&&navigator.clipboard.writeText(t.parentElement.textContent)})})})()</script>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</footer>
|
|
|
|
|
|
|
|
|
|
|
|
<div class="book-comments">
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
<label for="menu-control" class="hidden book-menu-overlay"></label>
|
|
|
</div>
|
|
|
|
|
|
|
|
|
</main>
|
|
|
|
|
|
|
|
|
</body>
|
|
|
</html>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|