Float buffer FloatBuffer in javaI. Overview:
java.lang.Object java.nio.Buffer java.nio.FloatBuffer
public abstract class FloatBuffer extends Buffer implements Comparable
This class defines four types of operations on the float Buffer:
Read
I don't think many of my friends will use the float type in mysql, especially when we use money, we may use double precision, we know that the float type of mysql is a single-precision floating point type, which may cause data errors accidentally.
I
Think a lot of friends are not how to use the float type in MySQL, especially when it comes to money we may use double precision, we know that the type of float of MySQL is single precision floating point type is careless will cause data
Usage of float type in mysql bitsCN.com
A single-precision floating point uses 4-byte (32bit) to represent a floating point.A computer floating point number that adopts the IEEE754 standard is represented in binary format internally.For example, 7.22
Single-precision floating-point numbers are 4 bytes (32bit) representing floating point numbersUses the IEEE754 standard computer floating-point number, in the interior is uses the binary system to representFor example: 7.22 with a 32-bit binary is
A single-precision floating point uses 4-byte (32bit) to represent a floating point.A computer floating point number that adopts the IEEE754 standard is represented in binary format internally.For example, 7.22 cannot be expressed in 32-bit
Single-precision floating-point numbers are 4 bytes (32bit) representing floating point numbersUses the IEEE754 standard computer floating-point number, in the interior is uses the binary system to representFor example: 7.22 with a 32-bit binary is
There are non-standard data types such as float,double in MySQL, as well as standard data types such as decimal. The difference is that non-standard types, such as float,double, hold approximate values in db, while decimal saves values as strings.
Single-precision floating-point number with 4 bytes (32bit) for floating-point numbers, using the IEEE754 standard computer floating-point number, in the interior is a binary representation, such as: 7.22 with 32-bit binary is not the case, so it
Some time ago to hit the code found something about the type of float strange phenomenon, take it out and share with you.Run the following code on Linux:#include int main () {float a=16777216;float b=16777217;float c=16777218;float d=16777219;float
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.