• Try solve A+B

    A+B
    Login: student1 
    Password: student

    C:
    #include <stdio.h>
    
    int main() {
        int a, b;
        scanf("%d %d", &a, &b);
        printf("%d\n", a + b);
        return 0;
    }
     
    C++:
    #include <iostream>
    using namespace std;
    
    int main() {
        int a, b;
        cin >> a >> b;
        cout << (a + b) << endl;
        return 0;
    }
     
    C# (Mono):
    using System;
    
    class Program {
        static void Main() {
            var inputs = Console.ReadLine().Split();
            int a = int.Parse(inputs[0]), b = int.Parse(inputs[1]);
            Console.WriteLine(a + b);
        }
    }
     
    Delphi:
    program SumAB;
    var
        a, b: Integer;
    begin
        ReadLn(a, b);
        WriteLn(a + b);
    end.
     
    Pascal:
    program SumAB;
    var
        a, b: Integer;
    begin
        ReadLn(a, b);
        WriteLn(a + b);
    end.
     
    Python 2:
    a, b = map(int, raw_input().split())
    print a + b
     
    Python 3:
    a, b = map(int, input().split())
    print(a + b)
     
    Java 11:
    import java.util.Scanner;
    
    public class Main {
        public static void main(String[] args) {
            Scanner sc = new Scanner(System.in);
            int a = sc.nextInt();
            int b = sc.nextInt();
            System.out.println(a + b);
        }
    }
     
    Java 17:
    import java.util.Scanner;
    
    public class Main {
        public static void main(String[] args) {
            Scanner sc = new Scanner(System.in);
            int a = sc.nextInt();
            int b = sc.nextInt();
            System.out.println(a + b);
        }
    }
     
    C++17:
    #include <iostream>
    using namespace std;
    
    int main() {
        int a, b;
        cin >> a >> b;
        cout << (a + b) << endl;
        return 0;
    }
     
    C++20:
    #include <iostream>
    using namespace std;
    
    int main() {
        int a, b;
        cin >> a >> b;
        cout << (a + b) << endl;
        return 0;
    }
     
    C# (.NET 6.0):
    using System;
    
    class Program {
        static void Main() {
            var inputs = Console.ReadLine().Split();
            int a = int.Parse(inputs[0]), b = int.Parse(inputs[1]);
            Console.WriteLine(a + b);
        }
    }
     
    Kotlin:
    fun main() {
        val (a, b) = readLine()!!.split(" ").map { it.toInt() }
        println(a + b)
    }
     
    Golang:
    package main
    
    import "fmt"
    
    func main() {
        var a, b int
        fmt.Scan(&a, &b)
        fmt.Println(a + b)
    }
     
    Ruby:
    a, b = gets.split.map(&:to_i)
    puts a + b
     
    JavaScript (d8):
    // These functions are added for input/output
    var [a, b] = readline().split(" ").map(Number);
    print(a + b);
     
    Rust:
    fn main() {
        let mut input = String::new();
        std::io::stdin().read_line(&mut input).unwrap();
        let nums: Vec<i32> = input
            .split_whitespace()
            .map(|s| s.parse().unwrap())
            .collect();
        let a = nums[0];
        let b = nums[1];
        println!("{}", a + b);
    }
     
    PHP 8.1:
    <?php
    [$a, $b] = explode(' ', trim(fgets(STDIN)));
    echo $a + $b;
     
    TypeScript (Bun):
    const input: string = await Bun.stdin.text();
    const [a, b]: number[] = input.trim().split(' ').map(Number);
    console.log(a + b);
     
    JavaScript (Bun):
    const input = await Bun.stdin.text();
    const [a, b] = input.trim().split(' ').map(Number);
    console.log(a + b);