We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9f657dd commit 0aa1994Copy full SHA for 0aa1994
1 file changed
Repl1.java
@@ -0,0 +1,22 @@
1
+/* Description
2
+You need to write a program that reads two numbers from the same line
3
+and prints their sum in the standard output. Numbers can be positive,
4
+negative or zero.
5
+
6
+The example of work.
7
+The example below shows inputs and the corresponding outputs.
8
+Your program should work in the same way.
9
+5 8
10
+13
11
+*/
12
13
+import java.util.Scanner;
14
15
+class Repl1 {
16
+ public static void main(String[] args) {
17
+ Scanner sc = new Scanner(System.in);
18
+ int a = sc.nextInt();
19
+ int b = sc.nextInt();
20
+ System.out.println(a + b);
21
+ }
22
+}
0 commit comments