We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
Java Output Formatting
Java Output Formatting
Sort by
recency
|
1458 Discussions
|
Please Login in order to post a comment
import java.util.Scanner;
public class Solution {
}
import java.io.; import java.util.;
public class Solution {
}
It really highlights how formatting can control the presentation of output—especially useful in console-based applications. 11xplay
lol guys this is what i did import java.util.Scanner;
public class Solution { static void f1(String s){ // String s = "cpp 65"; String[] parts = s.split(" "); String str = parts[0]; String num = parts[1]; String fin = ""; if (num.length()==2){ fin = "0" + num; } else if (num.length()==1){ fin = "00" + num; } else { fin = num; } int space = 15-str.length(); String gap = ""; for(int i=0;i
Java is such a powerful and versatile programming language! Its platform independence and strong object-oriented features make it a go-to choice for building everything from desktop applications to enterprise systems and Android apps. 11xplay