0
What is wrong with my java sacnner input code?
i cant find my mistake....plz tell me. https://code.sololearn.com/cl7vjLPCb1H9/?ref=app
1 Answer
+ 12
import java.util.Scanner;
public class Program {
public static void main(String[] args) {
Scanner s = new Scanner(System.in);
int a = s.nextInt();
int b = s.nextInt();
System.out.println(a+b);
}
}
/* Use an uppercased i (I) while taking an integer input using Scanner. And, you have a extra curly brace which isn't required... */