logo

Crowdly

Browser

Add to Chrome

Наведеним нижче кодом є простір імен System. class Class1 { рublic static ...

✅ The verified answer to this question is available below. Our community-reviewed solutions help you understand the material better.

Наведеним нижче кодом є простір імен System.

class Class1

{ рublic static int Сума()

{ int [] a = {1, 2, 3, 4, 5}, b = {1, 2, 3};

int s = 0;

for (int i = 0; i

{Try {s = a [i] + b [i]; }

catch (IndexOutOfRangeException)

{Console.Write ( "Виняток-1."); throw ; }

}

return s;

}}

class Test

{ рublic static void Main ()

{ int s = 21;

try {s = Class1.Сумма(); }

catch (IndexOutOfRangeException)

{Console.Write ( "Програму завершено."); }

Console.WriteLine ( "s =" + s);

}}

Вкажіть результат виведення на консоль після спроби запустити програму на компіляцію і виконання:

C# oop_class

More questions like this

Want instant access to all verified answers on moodle.chnu.edu.ua?

Get Unlimited Answers To Exam Questions - Install Crowdly Extension Now!

Browser

Add to Chrome