I am looking to create a batch file that, when ran, creates a random integer from 0 to 100 and then runs it through an if statement that checks whether it is odd or even. I\'ve
The following prints a random number between 0 and 99, and prints whether it's even or odd:
@echo off set /a num = %random% %% 100 echo %num% set /a odd = num %% 2 if %odd% EQU 1 (echo odd) else (echo even)