C# Programming - Operators - Discussion
Discussion Forum : Operators - General Questions (Q.No. 17)
17.
What will be the output of the C#.NET code snippet given below?
int a = 10, b = 20, c = 30;
int res = a < b ? a < c ? c : a : b;
Console.WriteLine(res);
Discussion:
15 comments Page 2 of 2.
NguyenNam said:
1 decade ago
if (10<20)
{
if( 10<30)
{
return c= 20
}
else
return a= 10
}
else
{
return b=20
}
{
if( 10<30)
{
return c= 20
}
else
return a= 10
}
else
{
return b=20
}
Prakash said:
1 decade ago
I didnt get it:- (.
Some one please explain properly.
Some one please explain properly.
Nivas said:
1 decade ago
What mean by : ? please explain. Am confused.
Divya said:
1 decade ago
Can anyone explain how the answer came?
Bhavika said:
1 decade ago
Please explain more briefly.
Post your comments here:
Quick links
Quantitative Aptitude
Verbal (English)
Reasoning
Programming
Interview
Placement Papers