Boolean value

From WikiMD's Food, Medicine & Wellness Encyclopedia

Boolean value is a type of data type used in computer programming and mathematical logic that has only two possible values: true or false. Named after the British mathematician George Boole, Boolean values are fundamental to Boolean algebra, a branch of algebra where values are truth values: true and false.

History[edit | edit source]

The concept of Boolean values was first introduced by George Boole in his 1847 work "The Mathematical Analysis of Logic". Boole's work was intended to solve problems in logic and set theory, but it has since found wide application in computer science and electrical engineering.

Usage in Programming[edit | edit source]

In computer programming, Boolean values are used to control flow control structures such as if statements and loops. They are also used in comparisons and logical operations.

For example, in the C programming language, the Boolean data type is represented by the keyword 'bool'. A Boolean variable can be assigned either 'true' or 'false', and these can be used in logical expressions.

Boolean Algebra[edit | edit source]

In Boolean algebra, Boolean values are used to represent truth values in logical expressions. The three basic operations of Boolean algebra are conjunction (AND), disjunction (OR), and negation (NOT). These operations can be used to build more complex expressions, which can be evaluated to a Boolean value.

For example, the expression (true AND false) evaluates to false, while (true OR false) evaluates to true.

See Also[edit | edit source]

References[edit | edit source]

Wiki.png

Navigation: Wellness - Encyclopedia - Health topics - Disease Index‏‎ - Drugs - World Directory - Gray's Anatomy - Keto diet - Recipes

Search WikiMD


Ad.Tired of being Overweight? Try W8MD's physician weight loss program.
Semaglutide (Ozempic / Wegovy and Tirzepatide (Mounjaro / Zepbound) available.
Advertise on WikiMD

WikiMD is not a substitute for professional medical advice. See full disclaimer.

Credits:Most images are courtesy of Wikimedia commons, and templates Wikipedia, licensed under CC BY SA or similar.

Contributors: Prab R. Tumpati, MD