how to convert boolean to int code example
Example 1: java cast bolean to int
int result = myBooleanVar ? 1 : 0;
Example 2: convert boolean to int
int val = (bool) ? 1 : 0;
int result = myBooleanVar ? 1 : 0;
int val = (bool) ? 1 : 0;