Loading...
Submission
Id When Author Problem Language CPU Memory Verdict
16855 2024-04-19 12:23:34 dnt A Plus B Java 107 ms 41828 kb Accepted
Test Cases
CPU Memory Verdict
1 104 ms 41828 kb Accepted
2 102 ms 38208 kb Accepted
3 100 ms 38188 kb Accepted
4 96 ms 40308 kb Accepted
5 107 ms 38568 kb Accepted
6 100 ms 41784 kb Accepted
Source Code
program.java
Download
  1. import java.util.Scanner;
  2.  
  3. public class Practice{
  4. public static void main(String[] args) {
  5.  
  6. Scanner sc = new Scanner(System.in);
  7. String line = sc.nextLine(); // Read the entire line
  8. String[] tokens = line.split(" "); // Split the line by space
  9. int a = Integer.parseInt(tokens[0]); // Parse the first token as integer
  10. int b = Integer.parseInt(tokens[1]); // Parse the second token as integer
  11. int sum = a + b;
  12. System.out.println(sum);
  13. }
  14. }
  15.  
  16.