Reputation: 93
I am using Eclipse to run my java programs but there is a problem with Eclipse's console that the input and output appears in the same console. For example
public static void main(String[] args) {
Scanner scan = new Scanner(System.in);
int t = scan.nextInt();
while(t-- > 0) {
int n = scan.nextInt();
System.out.println(n);
}
scan.close();
}
For this code let the input be
2
3
4
then the output that i gets looks like
2
3
43
4
Is there any way to get separate input and output and get the distinction in eclipse.
Upvotes: 1
Views: 127