novaa (①個亾)当前离线
学生
荣誉版主
xiaoxx 当前离线
三级士官
TOP
youxi01 当前离线
@echo off for /f "delims=" %%i in ('echo 33bathomebathome;4444bathome555bathome^|findstr "bathome"') do set test=%%i echo %test% pause>nul复制代码
梦想种子 当前离线
五级士官
随风 当前离线
@echo off set "Str=bathome112222bathome;l23333 33bathome;4444bathome555bathome" :loop set num=%str:*bathome=% call set var=a%%str:bathome%num%=%%a if not "%var%"=="aa" echo.%var:~1,-1% set str=%num% if "%str%"=="%var:~1,-1%" set "num=" if defined num goto loop pause复制代码
@echo off set "str=fdkljdlkdfdkljgflkk gffkljflkbathome;lkdf;ljkdg;lkfdbathome;dlfld;lkl;kl;l,.da/u/kbathomefdaffas" set "str=%str: =n#a#t#u#r#e%" set "str=%str:bathome= %" for /f "tokens=1-4 delims= " %%i in ("%str%") do ( call :conv "%%i" call :conv "%%j" call :conv "%%k" call :conv "%%l" ) pause&exit :conv set "s=%~1" set "s=%s:n#a#t#u#r#e= %" echo %s%复制代码
评分人数
ieutk 当前离线
@echo off set "str=fdkljdlkdfdkljgflkkgffkljflkbathome;lkdf;ljkdg;lkfdbathome;dlfld;lkl;kl;l,.da/u/kbathomefdaffas" set "str=%str:bathome=_%" for /f "tokens=1-4 delims=_" %%a in ("%str%") do ( echo %%a^ %%b^ %%c^ %%d) pause复制代码