Home / MCQ Bank / Computer
Computer Operators And Expressions In C Sharp

What will be the output of the following C# code? public static void Main(string[] args) { int a = 4; int c = 2; bool b = (a % c == 0 ? true : false); Console.WriteLine(b.ToString()); if (a/c == 2) { Console.WriteLine("true"); } else { Console.WriteLine("false"); } Console.ReadLine(); }

Select the best option to verify your answer:
Show Correct Answer
Correct Answer: Option C • TRUE TRUE

Related Computer Questions

What is the disadvantage of counting sort? Which of the following is true about the size of an ArrayList in Java? Which of the following evaluate the Normal probability density (with a given mean/SD) at a point? How many methods are there in the History object? The main elements of the __________ are the insertion point, end mark, mouse pointer, rulers, scroll bars, and status bar.