- @echo off
- setlocal enabledelayedexpansion
- for /f "delims=" %%a in ('dir /ad /b /s B\*') do (
- set /a a+=1
- set !a!=%%a
- echo !a!=%%a
- )
- set /p n=请输入
- set /a aa=!n!*!a!
- for /f "delims=" %%a in ('dir /a-d /b /s A *.*') do (
- set /a b+=1
- set /a c+=1
- if "!c!" gtr "!a!" set c=1
- call :a "%%a"
- if "!b!"=="!aa!" pause&exit
- )
- :a
- move %1 "!%c:"=%!"
- goto :eof
复制代码 不知道这样子行不? |