![]() |
China DOS Union-- Unite DOS · Advance DOS · Grow DOS --Union site: www.cn-dos.net Forum site: www.cn-dos.net/forum |
| Guest | Log in | Register | Members | Search | China DOS Union |
|
中国DOS联盟论坛 The time now is 2026-09-13 22:27 |
47,812 topics / 349,916 posts / today 0 new / 48,268 members |
| 论坛回收站 » Everyone, who can help translate the following code |
| Printable Version 8,555 / 0 |
| Floor1 wlf2r | Posted 2010-11-25 16:20 |
| 新手上路 Posts 11 Credits 15 From 安微 | |
|
:
@echo off&setlocal enabledelayedexpansion If it does not exist 1.txt, echo "1.txt does not exist, please save the content to be processed as 1.txt text" & pause & exit For /f %%i in (1.txt) do ( set /a x+=1 call :1 "%%i" x!x! set name=!name! x!x! ) For %%j in (%name%) do ( For /l %%i in (1,1,%n%) do set /p=!%%j_%%i! <nul echo. ) echo.&echo. set /p oo=Enter the specified number for interception of upper and lower lines: For /l %%i in (1,1,10) do ( For %%j in (%name%) do ( if defined x_x set ok%%j_%%i=!%%j_%%i! if !%%j_%%i! equ %oo% (call set ok!_tmp!=%%!_tmp!%%) else ( if not defined ok!_tmp! call set ok!_tmp!= ) set x_x=&set _tmp= if !%%j_%%i! equ %oo% (set x_x=x&set ok%%j_%%i=!%%j_%%i!) else ( set _tmp=%%j_%%i ) ) set x_x= ) For %%j in (%name%) do ( For /l %%i in (1,1,10) do set /p=!ok%%j_%%i! <nul echo. ) pause exit :1 set xx=%~1 set n=0 :2 set /a n+=1 if "%xx%" gtr "" (set %~2_%n%=%xx:~0,1%&set xx=%xx:~1%&goto 2) else (goto :eof) goto :eof Who can tell me the meaning of each line below and the role of these symbols, especially in the judgment statement |
|
|
[ Contact the Union admin team -
中国DOS联盟 -
Standard version ] Sponsored by ifanr Inc | © 2001–2023 |