C: printf a float value
You can do it like this:
printf("%.6f", myFloat);
6 represents the number of digits after the decimal separator.
printf("%9.6f", myFloat)
specifies a format with 9 total characters: 2 digits before the dot, the dot itself, and six digits after the dot.