Delphi-Quellcode:
var
A, X: Boolean;
// Pascal bzw. Delphi
B: ByteBool;
C: LongBool;
// C++ bzw. WinAPI
begin
A := True;
B := True;
C := True;
X := Boolean(9);
ShowMessage(Format('
%d %d %d %d'#10'
%.2x %.2x %.8x %.2x '#10'
%s',
[Ord(A), Ord(B), Ord(C), Ord(X),
Byte(A), Byte(B), LongWord(C), Byte(X),
BoolToStr(X = True, True)
// if X = True then ...
]));
Konstanten: 0 und 1 (bzw. -1, also ein oder alle Bits)
Auswertung: =0 und <>0 (aber niemals =1)