 In a previous video, we used system.out.format to create formatted output. We can also use the system.out.printf method, which does exactly the same thing, and it has a name that's more like our good friend's print and println. In this example, we had two format specifiers, and they were both for integers, the years and days. You can have as many format specifiers in your string as you want, and they don't all have to be the same data type. Here's a program that asks the user for the name of a store and reads it into a string, the number of customers and reads it in as an integer, and the total sales, which is a double. It then calculates the average sales per customer. Now, let's print that with system.out.printf. Our format string will give the number of customers, and because that's an integer, we use %d as the specifier, and the store name, which is a string, meaning we need the %s specifier, and the average amount of money spent, and the specifier for that will be a %.2, meaning we want two decimals places, and f for a floating point value, and end the sentence with a period, and we want a new line. We could use backslash n, but best programming practice is to use a special specifier, %n. It's not a placeholder, it means insert a new line. Now that we have the format string, we need to fill in the specifiers with the number of customers, the store name, and the average sales. Let's compile it and run it, where the store name is going to be Acme Gadgets. We'll have 23 customers who spent $832.43, and there's their average spending. You'll notice that this line in our source code is pretty long, and if we have style guidelines that say lines shouldn't be more than 80 characters, we have a problem. We can solve this problem by using string concatenation to split our format string into two parts on two shorter lines. We'll split the format string here, put a plus sign, and continue it on the next line. Now that we have the shorter lines, we can compile and again run the program and get the same output and conform to our guidelines. In summary, the important part of this video is printf is the same as format. You can have as many specifiers as you want in your format string. They don't all have to be the same data type, and percent sign in is what you should prefer over backslash in.