將數字與 IF 語句進行比較
SET TEST=0
IF %TEST% == 0 (
echo TEST FAILED
) ELSE IF %TEST% == 1 (
echo TEST PASSED
) ELSE (
echo TEST INVALID
)
SET TEST=0
IF %TEST% == 0 (
echo TEST FAILED
) ELSE IF %TEST% == 1 (
echo TEST PASSED
) ELSE (
echo TEST INVALID
)