本帖最后由 terse 于 2013-6-30 12:25 编辑
没测试 1000个变量的效率
添加8行 >
休息 | @echo off&setlocal enabledelayedexpansion | | set m=1000 | | for /f "delims=" %%i in (all.txt) do set /an+=1&set #!n!=%%i | | for /f "delims=" %%i in ('dir /b /a-d *.txt ^| findstr /ivx "all\.txt"') do ( | | (for /l %%a in (1 1 10) do ( | | set /a n=!random!%%m+1 | | for %%b in (!n!) do echo !#%%b! | | ))>>"%%i" | | ) | | pauseCOPY |
|