Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Represents the boolean value true.
Example
// cs_keyword_true.cs
using System;
class TestClass
{
static void Main()
{
bool a = true;
Console.WriteLine( a ? "yes" : "no" );
}
}
Output
yes
C# Language Specification
For more information, see the following sections in the C# Language Specification:
- 2.4.4.1 Boolean literals
See Also
Reference
C# Keywords
false (C# Reference)