Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if (boolean1 ^ boolean2)
- {
- //do it
- }
- if((boolean1 && !boolean2) || (boolean2 && !boolean1))
- {
- //do it
- }
- public static boolean xor(boolean a, boolean b) {
- return (a && !b) || (b && !a);
- }
- if (term1 ^ term2) { ...
- if((boolean1 && !boolean2) || (boolean2 && !boolean1))
- {
- //do it
- }
- if(boolean1 != boolean2)
- {
- //do it
- }
- str.contains("!=") ^ str.startsWith("not(")
- str.contains("!=") != str.startsWith("not(")
Add Comment
Please, Sign In to add comment