adplus-dvertising

Welcome to the Functions and Subroutines MCQs Page

Dive deep into the fascinating world of Functions and Subroutines with our comprehensive set of Multiple-Choice Questions (MCQs). This page is dedicated to exploring the fundamental concepts and intricacies of Functions and Subroutines, a crucial aspect of C# programming. In this section, you will encounter a diverse range of MCQs that cover various aspects of Functions and Subroutines, from the basic principles to advanced topics. Each question is thoughtfully crafted to challenge your knowledge and deepen your understanding of this critical subcategory within C# programming.

frame-decoration

Check out the MCQs below to embark on an enriching journey through Functions and Subroutines. Test your knowledge, expand your horizons, and solidify your grasp on this vital area of C# programming.

Note: Each MCQ comes with multiple answer choices. Select the most appropriate option and test your understanding of Functions and Subroutines. You can click on an option to test your knowledge before viewing the solution for a MCQ. Happy learning!

Functions and Subroutines MCQs | Page 3 of 3

Q21.
What will be the output of the C#.NET code snippet given below?

namespace CompSciBitsConsoleApplication
{
    class SampleProgram
    {
        static void Main(string[ ] args)
        {
            int i = 5;
            int j;
            fun1(ref i);
            fun2(out j);
            Console.WriteLine(i + ", " + j);
        }
        static void funl(ref int x)
        {
            x = x * x;
        }
        static void fun2(out int x)
        {
            x = 6; 
            x = x * x; 
        }
    }
}
Discuss
Answer: (c).25, 36
Page 3 of 3

Suggested Topics

Are you eager to expand your knowledge beyond C# programming? We've curated a selection of related categories that you might find intriguing.

Click on the categories below to discover a wealth of MCQs and enrich your understanding of Computer Science. Happy exploring!