백준/C#

[C#] 백준 10951번 : A+B - 4

joungdev 2025. 1. 23. 17:08

[C#] 백준 10951번 : A+B - 4

using System;

class Program
{
    static void Main()
    {
        while (true)
        {
            string a = Console.ReadLine();
            if (a == null) break;
            string[] numbers = a.Split(' ');

            int num1 = int.Parse(numbers[0]);
            int num2 = int.Parse(numbers[1]);

            Console.WriteLine(num1 + num2);
        }
    }
}

 

반응형

'백준 > C#' 카테고리의 다른 글

[C#] 백준 10871번 : X보다 작은 수  (0) 2025.01.24
[C#] 백준 10807번 : 개수 세기  (0) 2025.01.24
[C#] 백준 10952번 : A+B - 5  (0) 2025.01.23
[C#] 백준 2439번 : 별 찍기 - 2  (0) 2025.01.23
[C#] 백준 2438번 : 별 찍기 - 1  (0) 2025.01.23