|
@@ -56,9 +56,9 @@ public class LeetUtils {
|
56
|
56
|
return (String.format("name: %7s%6sseen: %d " + time, capitalizeMe(name), "", count));
|
57
|
57
|
}
|
58
|
58
|
|
59
|
|
- public static String stringFormatPrice(Double price, int count) {
|
|
59
|
+ public static String stringFormatPrice(Double price, int count, String label1, String label2) {
|
60
|
60
|
String time = (count > 1) ? "times" : "time";
|
61
|
|
- return String.format("%7s%6.2f%5s%7s%d " + time + "\n","Price: ", price,"", "seen: ", count);
|
|
61
|
+ return String.format("%7s%6.2f%5s%7s%d " + time + "\n",label1 + ": ", price,"",label2 + ": ", count);
|
62
|
62
|
}
|
63
|
63
|
|
64
|
64
|
public static String errorLine(int count) {
|