public static void main(String[] args){
int solution = 6;
System.out.println("Guess a number between 1 and 10");
Scanner userInputScanner = new Scanner (System.in);
int guess = userInputScanner.nextInt();
System.out.println("You guess the number "+ guess);
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.