Advertisement
Guest User

Untitled

a guest
Oct 17th, 2019
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.75 KB | None | 0 0
  1. package com.company;
  2.  
  3.  
  4. import java.util.Scanner;
  5.  
  6. public class Main {
  7.  
  8. public static void main(String[] args) {
  9.  
  10. Scanner keyboard = new Scanner(System.in);
  11. int count = 0;
  12. int a = 1 + (int) (Math.random() * 99);
  13. int guess = 0;
  14.  
  15. System.out.println("O jakim numerze mysle jebany pedale");
  16.  
  17. while (guess != a) {
  18. guess = keyboard.nextInt();
  19. count++;
  20. if (guess > a) {
  21. System.out.println("schodz w dol pedale");
  22. } else if (guess < a) {
  23. System.out.println("wyzej jebany gowniaku");
  24. }
  25. }
  26. System.out.println("Brawo zajelo ci to az: "
  27. + count + " proby cwelu");
  28. }
  29.  
  30. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement