Saturday, December 03, 2011

What In The World Is A Boolean? Common Computer Data Types

The word looks extremely weird and abstract, but the funny thing is that "boolean" is simply a YES or NO variable. It is a variable based on the simplest logic known to man: True or False.
Boolean variables are just that! TRUE or FALSE. 

(Java) Example #1:
boolean pass = false;

In example #1 (above): "boolean" is a keyword that tells the computer what the variable will be. "pass" is the name I chose to name this variable. " = false;" sets the value of "pass" to false.

The name "Boolean" came from the last name of George Boole, an English mathematician from the 1800's. In binary, a number system based on 2, often times, a numerical value of 1 is referred to as true, and a value of 0 is false. Boolean variables are extremely important in computer science, engineering, and electronics because it can simulate logic by use of electric current.

No comments: