fork(1) download
  1. /* package whatever; // don't place package name! */
  2.  
  3. import java.util.*;
  4. import java.lang.*;
  5. import java.io.*;
  6.  
  7. /* Name of the class has to be "Main" only if the class is public. */
  8. class Ideone
  9. {
  10. public static void main(String[] args) {
  11.  
  12. Random generator = new Random();
  13. int a = generator.nextInt(101);
  14.  
  15. Scanner scanner = new Scanner(System.in);
  16.  
  17. System.out.println("Podaj liczbe");
  18. int b = scanner.nextInt();
  19.  
  20. if ( b > a ){
  21. System.out.println(" wprowadzona liczba jest wieksza od liczby a");
  22. }
  23. }
  24. }
Success #stdin #stdout 0.12s 29440KB
stdin
200
stdout
Podaj liczbe
 wprowadzona liczba jest wieksza od liczby a