A.txt:
Code:
AA1 bB2 two cC3 three dD4 four eE5 five fF6 six gG7 seven hH8 eight iI9 nine
The output is as follows:
Code:
Abcdefghi
ABCDEFGHI
123456789
September 1234
The only requirement is that the veteran skipped it and left it for the novice to do exercises. The echo is not allowed directly.
Find the rule first.
Otherwise, it is not important to generate a temporary file or code more than one page. Correct output is enough.
523066680:
Copy codeThe Code is as follows: @ echo off
Setlocal enabledelayedexpansion
Set a =-1
For/f "tokens = *" % a in ('Type 1. x') do set hang = %
:
Set/a + = 1
Set/a B = % a %
: B
Set hang % a % =! Hang % a % !! Hang :~ % B %, 1!
Set/a B = % B % + 4
If not "! Hang :~ % B %, 1! "=" "Goto: B
Echo ,! Hang % a %!
If % a % leq 2 goto:
Pause
This idea is very direct, nothing special, that is, setting up
First Act 1, 5, 9, 13 ,...... Bit
Second act ...... Bit
WIND:Copy codeThe Code is as follows: @ echo off & setlocal EnableDelayedExpansion
Set "str = aA1 one bB2 two cC3 three dD4 four eE5 five fF6 six gG7 seven hH8 eight iI9 nine"
For/l % a in (0 1 35) do (
Set/a n + = 1
Call set .! N! = % .! N! %! Str :~ % A, 1!
Set/a n = n % 4
)
For/f "tokens = 2 delims =" % a in ('set. ') do echo %
Pause> nul
Terse:Copy codeThe Code is as follows: @ echo off & setlocal EnableDelayedExpansion
Set "str = aA1 one bB2 two cC3 three dD4 four eE5 five fF6 six gG7 seven hH8 eight iI9 nine"
For/l % I in (0 1 3) do for/l % j in (% I 4 35) do set % I =! % I !! Str :~ % J, 1!
For/l % I in (0 1 3) do echo! % I!
Pause> nul
Netbenton:Copy codeThe Code is as follows: @ echo off & setlocal ENABLEDELAYEDEXPANSION
Set "x = aA1 one bB2 two cC3 three dD4 four eE5 five fF6 six gG7 seven hH8 eight iI9 nine"
For/l % a in (0, 1, 3) do (for/l % B in (% a, 4, 35) do set/p =! X :~ % B, 1! <Nul) & echo .)
Pause