Код:
![Выделить весь код](images/misc/selectcode.png)
@echo off
for %%i in (
"d:\Install\1.bat"
"d:\Install\2.bat"
"d:\Install\3.bat"
) do (
call set batch_file_%%random%%=%%i
set /a count+=1
call set launches_%%random%%=%%count%%
)
set count=
for /f "tokens=1* delims==" %%i in ('
set batch_file_
') do (
for /f "tokens=2 delims==" %%k in ('
set launches_
') do (
set $launches=%%k
)
set /a count+=1
for /f "tokens=1,2" %%k in ('
call echo %%count%% %%$launches%%
') do (
if %%k leq %%l (
start "" %%j
)
)
)
exit /b