@echo off
setlocal enabledelayedexpansion
set /a x = !random!
echo !x! & echo;
call :time t
for /l %%i in (%t%, -1, 0) do (
set /a "y = ((%%i * 214013 + 2531011) >> 16) & 0x7fff"
if !y! equ !x! (
echo %%i
call :srand %%i
call :rand z
echo !z! & echo;
for /l %%j in (1, 1, 10) do (
call :rand z
echo !z! !random!
)
)
echo;
pause & exit
)
:time
setlocal
for /f "skip=1 tokens=1-9" %%a in ('wmic path win32_utctime ^| findstr .') do set /a m=%%e+9,m%%=12,y=%%i-m/10,t=365*y+y/4-y/100+y/400+(m*306+5)/10+%%a-719469,t=t*86400+%%c*3600+%%d*60+%%g
endlocal & set %1=%t% & goto :eof