Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

The second argument in the logging macros is a format specification, i.e. a pointer to a null-terminated multibyte string specifying how to interpret the data. As such, you can use any standard format specifier accepted by printf. Here's a small reference list: https://en.cppreference.com/w/cpp/io/c/fprintf

Also, from the same link: %g converts floating-point number to decimal or decimal exponent notation depending on the value and the precision.