I\'m wondering if there\'s a way to convert a boolean to an int without using if statements (as not to break the pipeline). For example, I could write
int bo
I found a solution by framework. Use compare for Boolean.
// b = Your boolean result // v will be 1 if b equals true, otherwise 0 int v = Boolean.compare(b, false);