I am trying to build a program that talks to the user and I want it to know as much as possible. For that I need an ability to use what the user types in my programs code and not just in variables in a way that it is fully implemanted in to the code Or if there is now way, you know of just Tell me and I will accept it.
Asked
Active
Viewed 453 times
1 Answers
0
The Scanner class can be used for input. Example:
Scanner scanner = new Scanner(System.in);
String age = "";
System.out.println("Please enter your age:");
age = scanner.next();
This code will get user input via the console.

brso05
- 13,142
- 2
- 21
- 40