Ok, in my intro java class we are tasked with creating a program that essentially gathers information from a number of other classes and then prints them out in one of a couple toStrings. This toString has a double (price) and there there is a call to another classes toString Pub1
I can't get this to work. The formatting is off. How would I format this correctly to display price in normal monetary format along with the others ?
return String.format("\n Title: %s \n Author: %s \n ISBN#: %s \n Price: $%.02f \n %s ", title, author, isbn, price, pub1.toString());
Thanks in advance guys!!
I can post more if needed!