且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

使用cout(C ++)打印未初始化的bool

更新时间:2023-11-10 23:08:10


这种行为是否符合标准?

Is this behavior compliant with the standard?

是的!在代码中使用垃圾值(未初始化)调用未定义行为

Yes! Using garbage values(uninitialized) in your code invokes Undefined Behavior