Top "Boolean" questions

A Boolean data type is a data type with only two possible values: true or false.

Shorthand for flipping a boolean variable

How can I flip the value of a boolean variable in javascript, without having to include the variable name twice? …

javascript boolean flip shorthand
What does !! (double exclamation point) mean?

In the code below, from a blog post by Alias, I noticed the use of the double exclamation point !!. I …

perl operators boolean negation
How to negate bool inside function in JS?

I'm writing some script now and I have a problem when trying to negate boolean inside a function. I mean …

javascript boolean negate
Change boolean Values?

I have a question about boolean values in Java. Let's say I have a program like this: boolean test = false; ... …

java boolean primitive-types
bool operator ++ and --

Today while writing some Visual C++ code I have come across something which has surprised me. It seems C++ supports ++ (…

c++ boolean increment
PostgreSQL: Create index for boolean column

I have a table that has one boolean column. productid integer isactive boolean When I execute the query SELECT productid …

postgresql boolean database-indexes
Keyword for exclusive or in ruby?

Does Ruby have a plain-English keyword for exclusive or, like they have "and" and "or"? If not, is this because …

ruby boolean xor
Boolean Expression Evaluation in Java

I'm looking for a relatively simpler (when compared with writing a parser) way to evaluate boolean expressions in Java, and …

java boolean expression evaluate
Why is bool a subclass of int?

When storing a bool in memcached through python-memcached I noticed that it's returned as an integer. Checking the code of …

python boolean
TypeError: endswith first arg must be str or a tuple of str, not bool

I was trying to count the occurrences of words which end with several suffixes. I thought that endswith would accept …

python python-3.x count boolean ends-with