I have this simplified code:
System.out.printf("%-*s Exam Percentage: %4.1f Final Grade: %c\n", VAR, "fox"+", "+"jim",25.3225, 'C');
Which, according to this and other resources, should produce a column 'VAR' characters wide to the effect of:
fox, jim Exam Percentage: 25.3 Final Grade: C
It runs through a for loop and VAR is the largest size of the first string.
I reconize the method:
System.out.printf("%-"+VAR+"s Exam Percentage: %4.1f Final Grade: %c\n", "fox"+", "+"jim",25.3225, 'C');
It works, but I am mainly curious. Also, the afore mentioned page mentions 'argsize' an explanation into that may provide some insight.
P.S. I know the the code has literals. Its for simplicity.