#include <stdio.h>
#include <float.h>
    
int main()
{
    printf("%f\n", FLT_MAX);
}

Output from GNU:

340282346638528859811704183484516925440.000000

Output from Visual Studio:

340282346638528860000000000000000000000.000000

Do the C and C++ standards allow both results? Or do they mandate a specific result?

Note that FLT_MAX = 2^128-2^104 = 340282346638528859811704183484516925440.

Edit
Report