- @echo off & setlocal enabledelayedexpansion
- for /f "tokens=1* delims=:" %%a in ('findstr /n .* a.txt') do set a%%a=%%b&set x1=%%a
- for /f "tokens=1* delims=:" %%a in ('findstr /n .* b.txt') do set b%%a=%%b&set x2=%%a
- set /a x=!x1!*!x2!,xx1=1,xx2=1
- for /l %%a in (1 1 !x!) do (
- call :xx
- set/a xx1+=1,xx2+=1
- if !xx1! gtr !x1! set xx1=1
- if !xx2! gtr !x2! set xx2=1
- )
- pause
- :xx
- call echo.%%a%xx1%%%%%b%xx2%%%
复制代码
|