I have been working on bringing old code from 1998 to the 21st century. One of the first steps in the process is to convert printf statements to QString variables. No matter how many times I look at printf again, I always forget one or the other. So, for fun, let me decode it together, for the sake of time and in the process, create the first small 'printf primer for Stackoverflow.
In the code, I came across this little gem,
printf("%4u\t%016.1f\t%04X\t%02X\t%1c\t%1c\t%4s", a, b, c, d, e, f, g);
How will the variables a, b, c, d, e, f, g be formatted?
source share