We all know about Ternary operator in C#.NET. I am a big fan of ternary operator and I like to use it instead of using IF..Else. Those who don’t know about ternary operator please go through below link.
http://msdn.microsoft.com/en-us/library/ty67wk28(v=vs.80).aspx
Here you can see ternary operator returns one of the two values based on the condition. See following example.
http://msdn.microsoft.com/en-us/library/ty67wk28(v=vs.80).aspx
Here you can see ternary operator returns one of the two values based on the condition. See following example.