Added function that returns 1 if a boolean value is true and false otherwise.