Skip to content

Latest commit

 

History

History
46 lines (34 loc) · 1022 Bytes

uint32_max.md

File metadata and controls

46 lines (34 loc) · 1022 Bytes

UINT32_MAX

  • cstdint[meta header]
  • macro[meta id-type]
  • cpp11[meta cpp]
# define UINT32_MAX implementation-defined

概要

uint32_t の最大値を表す定数。

ビット数32をNとして、このマクロの値は2N - 1である4294967295となる。

その値の型は、uint32_tを整数昇格したものとなる。

なお、このマクロは uint32_t が定義されていない場合には定義されない。

#include <iostream>
#include <cstdint>

int main()
{
  std::cout << UINT32_MAX << std::endl;
}
  • UINT32_MAX[color ff0000]

出力

4294967295

バージョン

言語

  • C++11

処理系

  • Clang: 3.2 [mark verified]
  • GCC: 4.4 [mark verified]
  • ICC: ??
  • Visual C++: 2010 [mark verified], 2012 [mark verified], 2013 [mark verified], 2015 [mark verified]