/** * Output: num is 5 char is a char is A bool is true */ public class MainClass { public static void main(String args[]) throws Exception { System.out.printf("num is %s\n", 5); System.out.printf("char is %s\n", 'a'); System.out.printf("char is %S\n", 'a'); System.out.printf("bool is %s\n", true ); } }