编译器的字节范围测试
来源:互联网 发布:node.exe是什么东西 编辑:程序博客网 时间:2024/05/22 12:30
#include<iostream>
#include<climits>
int main()
{
using namespace std;
int n_int=INT_MAX;
short n_short=SHRT_MAX;
long n_long=LONG_MAX;
long long n_llong=LLONG_MAX;
cout << "int is " << sizeof(int) << endl;
cout << "short is " << sizeof(short) << endl;
cout << "long is " << sizeof(long) << endl;
cout << "long long is " << sizeof(long long) << endl;
cout << endl;
cout << "maximum value:"<< endl;
cout << "int: " << n_int << endl;
cout << "short: " << n_short << endl;
cout << "long: " << n_long << endl;
cout << "long long: " << n_llong << endl;
cout << "minimum int value:"<< endl;
cout << INT_MIN << endl;
cout << "bite per byte= " << CHAR_BIT << endl;
}
#include<climits>
int main()
{
using namespace std;
int n_int=INT_MAX;
short n_short=SHRT_MAX;
long n_long=LONG_MAX;
long long n_llong=LLONG_MAX;
cout << "int is " << sizeof(int) << endl;
cout << "short is " << sizeof(short) << endl;
cout << "long is " << sizeof(long) << endl;
cout << "long long is " << sizeof(long long) << endl;
cout << endl;
cout << "maximum value:"<< endl;
cout << "int: " << n_int << endl;
cout << "short: " << n_short << endl;
cout << "long: " << n_long << endl;
cout << "long long: " << n_llong << endl;
cout << "minimum int value:"<< endl;
cout << INT_MIN << endl;
cout << "bite per byte= " << CHAR_BIT << endl;
}
阅读全文
0 0
- 编译器的字节范围测试
- 一个字节的表示范围
- 不同编译器的类型字节
- 1个字节表示数的范围
- C编译器的字节对齐方式
- java 变量范围的测试
- 测试部门的职责范围
- 测试编译器性能的源码
- 数值字节与范围
- 常用类型数据的字节数和表示的范围
- Hive - 运用于hadoop的拍字节范围数据仓库
- c#值类型数据的占用字节数和范围
- mysql的基本数据类型(数据类型---范围----字节------推荐存储)
- c++类型所占的字节和表示范围
- 各数据类型占用的内存字节数、范围
- (位、字节、字符)的表数范围
- 编译器与字节对齐
- 编译器与字节对齐
- spark-cluster及yarn-client说明
- Angularjs启动过程
- Oracle对于表中字段的相关操作
- 《Visual Basic 程序设计》——>文件
- java 正则表达式
- 编译器的字节范围测试
- 自己编译 LAMP Centos 7.2+Apache2.4+ Mysqlnd 5.6+PHP 7 详解
- UE4 C++ 定时器
- github搭建个人博客
- golang 线程与通道
- JAVA 类与对象
- 公钥和私钥
- Android 扩大ImageView的点击区域,解决按钮有效区域小的问题
- kafka->spark->streaming->mysql(scala)实时数据处理示例