C# Programming/Keywords/bool
Appearance
From Wikibooks, open books for an open world
The latest reviewed version was checked on 8 June 2017. There are template/file changes awaiting review.
C# Programming
Cover | Introduction | Basics | Classes | Advanced Topics | The .NET Framework | Index
Cover | Introduction | Basics | Classes | Advanced Topics | The .NET Framework | Index
The bool
keyword is used in field, method, property, and variable declarations and in cast
and typeof
operations as an alias for the .NET Framework structure System.Boolean
. That is, it represents a value of true
or false
. Unlike in C++, whose boolean is actually an integer, a bool
in C# is its own data type and cannot be cast to any other primitive type.
C# Keywords |
---|
Special C# Identifiers (Contextual Keywords) |
Contextual Keywords (Used in Queries) |