netdzb 当前离线
上尉
newswan 当前离线
TOP
Gin_Q 当前离线
五级士官
>>> import random>>> a = list(range(1,20))>>> a[1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19]>>> random.shuffle(a)>>> a[5, 14, 4, 6, 1, 12, 11, 13, 7, 3, 17, 10, 16, 8, 18, 19, 15, 9, 2]>>> COPY
qixiaobin0715 当前离线
大校
@echo offsetlocal enabledelayedexpansionfor /l %%a in (1,1,!n!) do set #!random!=%%afor /f "tokens=2 delims==" %%i in ('set #') do echo,%%ipauseCOPY
for /f "usebackq delims=" %%a in (`dir /b *.txt`) do ( call :f "%%a")for /f "usebackq tokens=2 delims==" %%a in (`set _`) do ( echo %%a) goto :END :fset n=%random%if defind _%n% goto :fset _%n%=%~1goto :eofCOPY