CODE: [Copy to clipboard]@echo off findstr /c:"2" 2.txt>nul if %errorlevel% equ 0 findstr /c:"2" 2.txt if %errorlevel% equ 1 (echo 2)>>2.txt pause