Strange float behaviour on Arduino Mega

@bojan_jurca

There is also the double type for floating point.
The drawback is that some boards map it to a 4 byte float while others handle it (more correctly) as full 8-byte floating points.

give this snippet a try.

double x;
Serial.println(sizeof(x));

Even then there are differences between the double on an embedded system and on a laptop. IIRC the Intel processor handles all double operation internally in 80 bit to optimize math, and store the results as 64 bit.
The SW-emulation of doubles in most boards just do all in 64 bits as that takes already enough time.