Absolute C++学习笔记2

简介: The main topics of the chapter2 are BOOLEAN EXPRESSION,BRANCHING MECHANISMS and LOOPS.

The main topics of the chapter2 are BOOLEAN EXPRESSION,BRANCHING MECHANISMS and LOOPS.

          There is a point which would be worth to notice,the point is int value can be used as boolean.The 0 would be recognised as false,the others would be recognised as true.

          Branching mechanisms have two kinds of method,if--else and switch--case.

          The third part introduces while,do--while and for statements.In this part,the author also introduce the comma operator,which use to get the last value to itself.The difference between while and do--while is the do--while statement will run one time at least,the while not.They have the same result in the other environment.

        

目录
相关文章
|
18天前
|
C++
c++学习笔记07 结构体
C++结构体的详细学习笔记07,涵盖了结构体的定义、使用、数组、指针、嵌套、与函数的交互以及在结构体中使用const的示例和解释。
30 0
|
5天前
|
安全 C语言 C++
C++学习笔记
C++学习笔记
|
18天前
|
算法 C++
c++学习笔记04 数组
这篇文章是C++学习笔记4,主题是数组。
35 4
|
17天前
|
C++
【学习笔记】【C/C++】 c++字面值常量
【学习笔记】【C/C++】 c++字面值常量
25 1
|
18天前
|
存储 C++
c++学习笔记05 函数
C++函数使用的详细学习笔记05,包括函数的基本格式、值传递、函数声明、以及如何在不同文件中组织函数代码的示例和技巧。
24 0
c++学习笔记05 函数
|
17天前
|
编译器 C++
【C/C++学习笔记】C++声明与定义以及头文件与源文件的用途
【C/C++学习笔记】C++声明与定义以及头文件与源文件的用途
28 0
|
17天前
|
存储 C++
【C/C++学习笔记】string 类型的输入操作符和 getline 函数分别如何处理空白字符
【C/C++学习笔记】string 类型的输入操作符和 getline 函数分别如何处理空白字符
29 0
|
18天前
|
C++
c++学习笔记09 引用
C++引用的详细学习笔记,解释了引用的概念、语法、使用注意事项以及引用与变量的关系。
31 0
|
18天前
|
存储 程序员 编译器
c++学习笔记08 内存分区、new和delete的用法
C++内存管理的学习笔记08,介绍了内存分区的概念,包括代码区、全局区、堆区和栈区,以及如何在堆区使用`new`和`delete`进行内存分配和释放。
31 0
|
18天前
|
存储 C++
c++学习笔记06 指针
C++指针的详细学习笔记06,涵盖了指针的定义、使用、内存占用、空指针和野指针的概念,以及指针与数组、函数的关系和使用技巧。
28 0