本帖最后由 jellyhk 于 2011-12-16 11:12 编辑
- @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! == !n! pause&exit
- )
- :a
- move %1 "!%c:"=%!"
- goto :eof
复制代码 这样不知道行不!请看到6楼的问题会的帮忙解惑! |