List of usage examples for java.lang System out
PrintStream out
To view the source code for java.lang System out.
Click Source Link
From source file:Main.java
public static void main(String[] args) { String text = " t "; System.out.println("Result: " + text.trim()); }
From source file:Main.java
public static void main(String args[]) { long l = 0x7ffffffffffffffL; System.out.println("l is " + l); }
From source file:Main.java
public static void main(String[] arg) { System.out.println("Type something"); try {/*w ww . ja v a2s .c o m*/ System.in.read(); } catch (IOException e) { e.printStackTrace(); } }
From source file:MainClass.java
public static void main(String[] arg) { short smallNumber = 1234; System.out.println(smallNumber); }
From source file:Main.java
public static void main(String[] args) { String text = "a b c e a b"; System.out.println(text.replaceFirst("(?:a b)+", "x y")); }
From source file:Main.java
public static void main(String args[]) { int days[] = { 31, 28, 31, }; System.out.println("days[2] is " + days[2]); }
From source file:Main.java
public static void main(String[] args) { System.out.println(getMonthByCode(2)); }
From source file:MainClass.java
public static void main(String[] a) { int percentage = 75; System.out.printf("\n%1$d%%", percentage); String str = "The quick brown fox."; System.out.printf("%nThe string is:%n%s%n%1$25s", str); }
From source file:Main.java
public static void main(String args[]) { System.out.println(new DecimalFormat("0.######E0").format(12345)); }
From source file:MainClass.java
public static void main(String[] arg) { double a = 12.12; System.out.println(a--); System.out.println(a++);/*from w w w .j av a 2 s . co m*/ System.out.println(--a); System.out.println(++a); }