- @echo off&setlocal enabledelayedexpansion
- for /f "delims=" %%i in ('dir /b /on *.txt') do (
- set str=%%~ni
- if "!str:~1,1!"=="" echo !str!%%~xi
- )
- for /f "delims=" %%i in ('dir /b /on *.txt') do (
- set str=%%~ni
- if not "!str:~1,1!"=="" echo !str!%%~xi
- )
- pause
复制代码
|