EQV
a EQV b
Bitwise equivalence.
Truth table:
a | b | a EQV b |
---|---|---|
0 | 0 | 1 |
0 | 1 | 0 |
1 | 0 | 0 |
1 | 1 | 1 |
Example 1: Print truth table
print "0 eqv 0 = " + bin(0 eqv 0)
print "0 eqv 1 = " + bin(0 eqv 1)
print "1 eqv 0 = " + bin(1 eqv 0)
print "1 eqv 1 = " + bin(1 eqv 1)
Example 2: Bitwise equivalence of two numbers
0b110010011111000010101011
a = 0b101010010101011100010101
b =
print " " + bin(a)
print "EQV " + bin(b)
print "----------------------------"
print " " + bin(a eqv b)
' Output:
'
' 110010011111000010101011
' EQV 101010010101011100010101
' ----------------------------
' 100111110101100001000001
Language
AND
AS
BAND
BG
BOR
BYREF
CALL
CASE
CATCH
CONST
DECLARE
DEF
DO
ELIF
ELSE
ELSEIF
END
END TRY
ENDIF
EQV
EXIT
FALSE
FI
FOR
FUNC
GOSUB
GOTO
IF
IFF
IMP
IN
LABEL
LET
LIKE
LOCAL
LSHIFT
MDL
MOD
NAND
NEXT
NOR
NOT
ON
OR
REM
REPEAT
RETURN
RSHIFT
SELECT
STEP
STOP
SUB
THEN
THROW
TO
TRUE
TRY
UNTIL
USE
USG
USING
WEND
WHILE
XNOR
XOR
If there is insufficient information on this page and you wish learn more about EQV,
please send an email to smallbasic@gmail.com. You can help to improve information about
EQV by submitting a pull request,
click View Source for details. Note, an offline language reference text file is also available - see the Download section.