wang3623246 当前离线
列兵
aych 当前离线
TOP
flyinnet9 当前离线
少尉
@echo off setlocal enabledelayedexpansion set /a folder=1 for /f "tokens=1 delims=" %%a in ('dir /b *.txt') do ( if !n!==30 set /a folder+=1 & set n= md !folder! 2>nul move "%%a" .\!folder! set /a n+=1 )复制代码
狗屁不通 当前离线
上尉
尘丶 当前离线
四级士官
@echo on&setlocal enabledelayedexpansion set num=1 for /l %%a in (1,1,30) do md %%a>nul 2>nul for /f "tokens=1,2 delims=." %%a in ('dir /b *.txt') do ( set /a n+=1 copy %cd%\"%%a".%%b %cd%\!num! if !n!==30 (set /a num=!num!+1&set n=) ) pause复制代码
set num=1 for /l %%a in (1,1,30) do md %%a for /f %%a in ('dir /b *.txt') do ( set /a n+=1 copy %cd%\%%a %cd%\!num!\ if n==30 (set /a num+=1) ) pause复制代码