- Online Exam Test Papers | - MCQs[multiple choice questions and answers ] | - Mock Test Papers | - Practice Papers | - Sample Test Papers |

Question:
Which of the following will be the correct output for the C#.NET program given below?

namespace IndiabixConsoleApplication
{ 
    class SampleProgram
    { 
        static void Main(string[] args)
        {
            int a = 5; 
            int s = 0, c = 0;
            Proc(a, ref s, ref c);
            Console.WriteLine(s + " " + c);
        }
        static void Proc(int x, ref int ss, ref int cc)
        {
            ss = x * x;
            cc = x * x * x;
        } 
    } 
}

1. 0 0

2.25 25

3.125 125

4.25 125

Posted Date:-2021-02-24 10:36:42


More MCQS Questions and answers

Search