How to specify 64 bit integers in c

后端 未结 5 1962
予麋鹿
予麋鹿 2020-12-07 23:58

I\'m trying to use 64 bit integers in C, but am getting mixed signals as to whether it should be possible.

When I execute the printf:

printf(\"Size o         


        
5条回答
  •  长情又很酷
    2020-12-08 00:56

    Use stdint.h for specific sizes of integer data types, and also use appropriate suffixes for integer literal constants, e.g.:

    #include 
    
    int64_t i2 = 0x0000444400004444LL;
    

提交回复
热议问题