- @echo off
- setlocal enabledelayedexpansion
- >"e.txt" type nul
- for /f %%i in ('more "a.txt"') do (
- if "%%~xi" neq "" (
- set "file=%%i"
- set "file=!file:~0,-1!"
- findstr /i /x "!file!" "b.txt" > nul
- if errorlevel 1 (
- >"f.txt" echo !file!
- goto :eof
- ) else (
- >>"e.txt" echo !file!
- )
- )
- )
复制代码
|