Biblioteca Java - Blame information for rev 4

Subversion Repositories:
Rev:
Rev Author Line No. Line
4 mihai 1 package introducere.java;
2  
3 import java.io.*;
4 import java.util.*;
5  
6 public class Joc {
7     public static void main(String[] args)throws Exception {
8         Random r = new Random();
9         BufferedReader t = new BufferedReader(new InputStreamReader(System.in));
10  
11         int x = r.nextInt(100);    
12         int a = -1;
13         while(a!=x){
14             String s = t.readLine();
15             a = Integer.parseInt(s);
16             if(a<x)
17                System.out.println("Numarul introdus este prea MIC");
18             else if(a>x)
19                System.out.println("Numarul introdus este prea MARE");
20         }
21  
22         System.out.println("Ati ghicit!");    
23  
24     }
25 }