当前位置:网站首页>02.1.2. logic type bool
02.1.2. logic type bool
2022-07-28 10:51:00 【vv1025】
//02.1.2. Logical type bool
//c Logical truth and falsehood of language 0 He Fei 0 To express . and C++ There are specific types in , But its essence , Is still
// One char Variables of type can be 0 He Fei 0 Data assignment of .
#include <iostream>
#include <stdio.h>
using namespace std;
int main() {
bool flag = true;
if(flag)
printf("flag is true\n");
else
printf("flag is flase\n");
printf("sizeof(flag) = %d sizeof(bool) = %d\n", sizeof(flag), sizeof(bool));
flag = 100;
printf("flag = %d\n", flag);
return 0;
}flag is true
sizeof(flag) = 1 sizeof(bool) = 1
flag = 1
-----------------------------------------------
Process returned: 0 (0x0)
Execution time: 371 ms
Maximum memory use: 276 KB
-----------------------------------------------
Press any key to continue . . .边栏推荐
猜你喜欢

ICML 2022 | 图表示学习的结构感知Transformer模型

Yan reports an error: exception message: /bin/bash: line 0: fg: no job control

Pyqt5 rapid development and practice 4.12 calendar and time

GKSpheresNoiseSource

6. MapReduce custom partition implementation

Blue Bridge Cup embedded Hal library USART_ TX

蓝桥杯嵌入式-HAL库-USART_TX

SQL Server 2016 learning records - set query

哈希表的相关知识点

GKConstantNoiseSource
随机推荐
20200229 training match L1 - 2 delete the substring in the string (20 points)
判断数码管是共阳极还是共阴极
Blue Bridge Cup embedded Hal library USART_ RX
Test question discovery ring of previous test questions
Lucene query syntax memo
SQL Server 2016 learning record - nested query
产品端数据分析思维
c语言进阶篇:指针(一)
Tensorflow knowledge points
GKObstacle
从零开始Blazor Server(2)--整合数据库
蓝桥杯嵌入式-HAL库-ADC
Operation log of dbeaver
Arduino Basics
生成对抗网络在DeepFake中的未来
SemEval 2022 | 将知识引入NER系统,阿里达摩院获最佳论文奖
剑指 Offer 09. 用两个栈实现队列
GKBillowNoiseSource
andorid 开发
蓝桥杯嵌入式-HAL库-USART_RX