fork download
  1. /* package whatever; // don't place package name! */
  2.  
  3. import java.util.*;
  4. import java.lang.*;
  5. import java.io.*;
  6. import java.math.*;
  7.  
  8. /* Name of the class has to be "Main" only if the class is public. */
  9. class Main {
  10. public static void main(String[] args) {
  11. System.out.println("欢迎关注!");
  12. BigDecimal d1 = new BigDecimal(10);
  13. System.out.println(d1.toString());
  14. BigDecimal d2 = new BigDecimal("12");
  15. System.out.println(d2.compareTo(d1)<=0);
  16. }
  17. }
Success #stdin #stdout 0.1s 55328KB
stdin
Standard input is empty
stdout
欢迎关注!
10
false