当前位置:网站首页>基础数据之double和float区别
基础数据之double和float区别
2022-08-11 05:13:00 【SunForYou】
测试用例:
public static void main(String[] args) {
Object[]strings = new Object[]{2.555555555555555555,2.555555555555555555f};}
可以发现
Param first 2.555555555555554 (16位) double
Param second 2.5555556 (7位) float
double类型消耗内存是float的两倍
double类型比float运算速度慢得多
边栏推荐
- FPGA engineer interview questions collection 111~120
- Unity WebGL RuntimeError: integer overflow
- 2022年Android面试中最常问的问题是什么?
- MySQL存储引擎概念
- Switch and Router Technology-35-NAT to PAT
- MySQL必知必会(初级篇)
- Idea essential skills to improve work efficiency
- 面试宝典一: code题目记录
- 【嵌入式开源库】使用J-Link打印日志,让你节省一个打印串口
- 实战noVNC全过程操作(包含遇到的问题和解决)
猜你喜欢
随机推荐
2022 Quality Officer-Civil Construction Direction-General Basic (Quality Officer) Exam Mock 100 Questions and Online Mock Exam
让你代码越来越高大上的技巧——代码规范,你得知道
Let's talk programming languages together
[No 2022 Shanghai Security Officer A Certificate Exam Question Bank and Mock Exam
Map根据key值排序
Switch and Router Technology-31-Extended ACL
MySQL数据库管理
【无2022上海市安全员A证考试题库及模拟考试
DS220702-0707作业
UML基本概念——动态视图
Switch and Router Technology - 36-Port Mirroring
Golden Warehouse Database KingbaseGIS User Manual (6.10. Geometric Object Operation Operator)
How to use svg-icon (svg-sprite-loader plugin)
Tips to make your code more and more taller and taller - code specification, you have to know
FPGA engineer interview questions collection 121~130
C language antithesis: who is the murderer!
Weekly recommended short video: your commonly used Polaroid, its predecessor turned out to be like this!
2022 coal mine gas inspection test, simulation test question and answer
Delphi7 learning record - demo example
【嵌入式开源库】使用J-Link打印日志,让你节省一个打印串口









