Boolean value

From WikiMD's 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]

WikiMD
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's Wellness Encyclopedia

Let Food Be Thy Medicine
Medicine Thy Food - Hippocrates

Medical Disclaimer: WikiMD is not a substitute for professional medical advice. The information on WikiMD is provided as an information resource only, may be incorrect, outdated or misleading, and is not to be used or relied on for any diagnostic or treatment purposes. Please consult your health care provider before making any healthcare decisions or for guidance about a specific medical condition. WikiMD expressly disclaims responsibility, and shall have no liability, for any damages, loss, injury, or liability whatsoever suffered as a result of your reliance on the information contained in this site. By visiting this site you agree to the foregoing terms and conditions, which may from time to time be changed or supplemented by WikiMD. If you do not agree to the foregoing terms and conditions, you should not enter or use this site. 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