In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-27 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)05/31 Report--
This article mainly explains "how many bytes python floating point accounts for". The content of the explanation is simple and clear, and it is easy to learn and understand. Please follow the editor's train of thought to study and learn how many bytes python floating point accounts for.
The operating environment of this tutorial: windows7 system, Python 3.9.1 Dell G3 computer.
1. Floating-point digit section
The float type occupies 4 bytes of memory and represents small numbers, with a data range of-2 ^ 128 ~ 2 ^ 128 (- 3.40E+38 ~ + 3.40E+38); the float data type is used to store single-precision or double-precision floating points.
2. Floating point number description
The float data type is used to store single-precision or double-precision floating points. Floating point is in IEE (Institute of Electrical and Electronic Engineers) format. The single-precision value of a floating-point type consists of four parts: number, Mantissa, index, and index. Because the high sequence bit of the Mantissa is always 1, it is not stored in digital form.
3. Two types of floating point numbers
The type descriptors of single precision and double precision are float single precision descriptor and double double precision descriptor. In TurboC, the single precision type occupies 4 bytes (32 bits) of memory space, the numerical range is 3.4E-38~3.4E+38, and can only provide 7 significant digits. The double precision type occupies 8 bytes (64 bits) of memory space, the numerical range is 1.7E-308~1.7E+308, and can provide 16 significant digits. Python defaults to 17-digit precision.
Thank you for your reading, the above is the content of "how many bytes python floating point accounts for". After the study of this article, I believe you have a deeper understanding of the problem of how many bytes python floating point accounts for, and the specific use needs to be verified in practice. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un