package zy03;
import java.util.Scanner;
import java.util.Random;
public class DEMO {
public static void main(String[] args) {
// TODO Auto-generated method stub
int rand=(int)(Math.random()*30)+20;
int count=0;
Scanner input=new Scanner(System.in);
int guess;
do {
guess=input.nextInt;
if(rand>guess) {
System.out.println("猜小了");
count++;
}
else if(rand<guess){
System.out.println("猜大了");
count++;
}else {
count++;
break;}
}while(count<5);
System.out.println("猜对了");
}
}