1、变量设置
for /l %%i in (1,1,100) do @echo %%i
set /a i=500
set /a i=%i%+200
echo %i%
pause++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
@echo off
SETLOCAL ENABLEDELAYEDEXPANSION
for /l %%i in (1 1 10) do (
set /a var=%%i+2
echo !var!
echo %var%
)++++++++++++++++++++++++++++++++++++++++++++++
@echo off
setlocal enabledelayedexpansion
set num=12
for /l %%i in (1,1,5) do (
set /a num+=10
echo !num!
)
pause