9.bool类型

2020-12-11  本文已影响0人  lxr_

#include<iostream>

using namespace std;

int main()

{

    bool flag = true;

    cout << "bool类型占" << sizeof(flag) << "字节" << endl;//bool类型占1个字节

    system("pause");

    return 0;

}

上一篇 下一篇

猜你喜欢

热点阅读