标题: 删除两文件中相同行的程序
[打印本页]
作者: tongwandou
时间: 2007-4-22 07:26
标题: 删除两文件中相同行的程序
新手写的一个删除两文件中相同行的程序.请大侠批评!!
@echo off
for /f "delims=" %%i in(1.txt) do type 2.txt | find "%%i" & if errorlevel 1 echo.%%i>>3.txt
for /f "delims=" %%j in(2.txt) do type 1.txt | find "%%j" & if errorlevel 1 echo.%%j>>3.txt
for /f %%k in (3.txt) do if not defined %%f set %%f=A & echo.%%f>>完成.txt
::此句是抄袭咱们论坛上一位大侠的代码,代码是背下了,但忘了是哪位的,不好意思.
作者: tongwandou
时间: 2007-4-22 07:56
怎么没人来指导批评下?自己坐个沙发!