依山居 ( 伸手党去死,私信问问题的去死)当前离线
中尉
print("=======================论回字的第五种写法============") l=list(a) ta=tb=tc=td='' for r in range(0,9): ta+=l.pop(0) tb+=l.pop(0) tc+=l.pop(0) td+=l.pop(0) print(ta) print(tb) print(tc) print(td)复制代码
TOP
print("==========试试回字的第六种写法好不好使==========") lena=len(a) t='' lena=len(a) for s in range(0,4): t='' for l in range(s,lena,4): t+=a[l] print(t)复制代码
taofan712 当前离线
六级士官
@echo off &setlocal enabledelayedexpansion set var=aA1一bB2二cC3三dD4四eE5五fF6六gG7七hH8八iI9九&set /a a=0 :loop for /l %%a in (%a%,4,36) do set/p=!var:~%%a,1!<nul echo;&if !a! lss 3 set /a a+=1 & goto loop pause&exit复制代码
lengmoke 当前离线
列兵
@echo off & setlocal EnableDelayedExpansion set strs=aA1一bB2二cC3三dD4四eE5五fF6六gG7七hH8八iI9九 :loop set str=!strs:~0,4! for /l %%i in (0,1,3) do ( set "str%%i=!str%%i!!str:~%%i,1!" ) set strs=!strs:~4! if defined strs ( goto :loop ) for /l %%i in (0,1,3) do ( echo !str%%i! )复制代码
qixiaobin0715 当前在线
大校
@echo off setlocal enabledelayedexpansion set var=aA1一bB2二cC3三dD4四eE5五fF6六gG7七hH8八iI9九 :a set /a n+=1 set /a m=(n-1)%%4 set str%m%=!str%m%!!var:~%m%,1! if %m%==3 set var=%var:~4% if not "%var%"=="" goto a for /l %%a in (0,1,3) do echo,!str%%a! pause复制代码