? Logical XOR ● SmileBASIC Source

Sign In

Register
*Usernames are case-sensitive
Forgot my password

Logical XOR

SB has logical NOT, AND, and OR (!, &&, ||), but not XOR. However, you can just use:!(A)!=!(B)
Author
12Me21
Updated
Rating
2 votes
Categories
Keywords
  • XOR
4 Comment(s) DizzyDude DizzyDude Video Games I like to play video games! Hobbies Night Person I like the quiet night and sleep late. Express Yourself Avatar Taboo I didn't change my avatar for 180 days Website helpful [sorta] Minxrod Minxrod Third Year My account is over 3 years old Website Expert Programmer Programming no longer gives me any trouble. Come to me for help, if you like! Programming Strength Video Games I like to play video games! Hobbies I just need autoEnable% = autoEnable% XOR (getButton% AND #Y) So it should work just fine :) EDIT: Might do it another way I just realized, haha. 12Me21 12Me21 Syntax Highlighter Received for creating the code syntax highlighter on SBS Night Person I like the quiet night and sleep late. Express Yourself You will neeed parentheses if you are using more than just a single number/variable since ! Comes first in th order of operations Minxrod Minxrod Third Year My account is over 3 years old Website Expert Programmer Programming no longer gives me any trouble. Come to me for help, if you like! Programming Strength Video Games I like to play video games! Hobbies Thanks! This will be very useful, I needed something like this for a toggle option.