+ 3
looks like your program needs input
I can't find where to put the input? and a message pops up saying split into multiple lines
5 Respuestas
+ 3
This is also my problem, I am using JAVA scanner. I can't seem to find where to type my input.
+ 2
@Erwin Mesias
This is the simple program I write at the code playground.
my problem is I don't know what to type to "Seems like your program requires input"
And I try to put anything there and whenever I want to type my name on the output area.
import java.util.Scanner;
public class Program
{
public static void main(String[] args) {
Scanner asa = new Scanner (System.in);
System.out.println("Type your name: ");
String name = asa.nextLine();
}
}
here is the simple program I make to ask for an input.
+ 1
@Stuart Harrison,
are you pertaining to the Code Playground?
if your code needs inputs,
you must enter all your inputs by the time you started running your code.
if you need multiple inputs,
place them into separate line by pressing the "nextLine button" ⬅⬇
+ 1
@John Angelo Cuesta
if you are inputting a String,
use scan.next() or scan.nextLine()
if you need an int,
use scan.nextInt()
if you need a decimal number,
use scan.nextDouble() or scan.nextFloat() depending on the precision you need.
- 2
Just type your name after clicking on the empty space under this popped text