[Jprogramming] Integer vector takes same amount of space as floating point one?

Elijah Stone elronnd at elronnd.net
Mon Oct 11 23:45:59 UTC 2021


On Mon, 11 Oct 2021, Devon McCormick wrote:

> Shouldn't a floating-point array take up more space than an integer 
> array of the same shape?

Except for booleans, integers are the size of a native machine word, which 
is usually 8 bytes.  Floating-point numbers are double-precision, and 
hence also 8 bytes.

  -E


More information about the Programming mailing list