## 子母图形

**问题描述**

```
利用字母可以组成一些美丽的图形，下面给出了一个例子：

ABCDEFG

BABCDEF

CBABCDE

DCBABCD

EDCBABC

这是一个5行7列的图形，请找出这个图形的规律，并输出一个n行m列的图形。
```

**输入格式**

```
输入一行，包含两个整数n和m，分别表示你要输出的图形的行数的列数。
```

**输出格式**

```
输出n行，每个m个字符，为你的图形。
```

**样例输入**

```
5 7
```

**样例输出**

```
ABCDEFG
BABCDEF
CBABCDE
DCBABCD
EDCBABC
```

**数据规模与约定**

```
1 <= n, m <= 26。
```


```
mn=list(map(int,input().split()))
q=['A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z'
]
t1=q[0:mn[1]]
print(''.join(t1))
#print('t1',t1[1],type(t1[1]))

for i in range(1,mn[0]):
    if i==1:
        print( ''.join(list(t1[1])+t1[0:-i]))
    else:
        t2[:]=reversed(t1[1:i+1])
        print(''.join(t2+t1[0:-i]))
```


```
mn=list(map(int,input().split()))
q=['A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z'
]
t1=q[0:mn[1]]
print(''.join(t1))
#print('t1',t1[1],type(t1[1]))
j=1
start=0
for i in range(1,mn[0]):
    if j==1:
        print( ''.join(list(t1[1])+t1[start:-j]))
    else:
        t2[:]=reversed(t1[start+1:j+1])
        print(''.join(t2+t1[start:-j]))
    j=j+1
    if j>=mn[0]:
        j=j-mn[0]
        start+=1
```

**上面的思路错了，下面的是对的**


```
def op1(mn,t1):
    print(''.join(t1[0:mn[1]]))
    #print('t1',t1[1],type(t1[1]))
    re=[]
    for i in range(1,mn[0]):
        if i==1:
            re=list(t1[1])+t1[0:-i]
            print(''.join(re[0:mn[1]]))
        else:
            t2=[]
            t2[:]=reversed(t1[1:i+1])
            re=t2+t1[0:-i]
            print(''.join(re[0:mn[1]]))


mn=list(map(int,input().split()))
q=['A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z']
op1(mn,q)

```

    20 20
    ABCDEFGHIJKLMNOPQRST
    BABCDEFGHIJKLMNOPQRS
    CBABCDEFGHIJKLMNOPQR
    DCBABCDEFGHIJKLMNOPQ
    EDCBABCDEFGHIJKLMNOP
    FEDCBABCDEFGHIJKLMNO
    GFEDCBABCDEFGHIJKLMN
    HGFEDCBABCDEFGHIJKLM
    IHGFEDCBABCDEFGHIJKL
    JIHGFEDCBABCDEFGHIJK
    KJIHGFEDCBABCDEFGHIJ
    LKJIHGFEDCBABCDEFGHI
    MLKJIHGFEDCBABCDEFGH
    NMLKJIHGFEDCBABCDEFG
    ONMLKJIHGFEDCBABCDEF
    PONMLKJIHGFEDCBABCDE
    QPONMLKJIHGFEDCBABCD
    RQPONMLKJIHGFEDCBABC
    SRQPONMLKJIHGFEDCBAB
    TSRQPONMLKJIHGFEDCBA



```
a=[1,2,3,3.3]
for i in a:
    print(i,end='')
```

    1122333.33.3


```
print(chr(65))
```

    A



```
m,n=map(int,input().split())
s=0
for i in range(m):
    k=65+i
    for j in range(n):
        print(chr(k), end='')
        if k==65:
            s=1
        if s==0:
            k=k-1
        else:
            k=k+1
    s=0
    print()
```

    20 20
    ABCDEFGHIJKLMNOPQRST
    BABCDEFGHIJKLMNOPQRS
    CBABCDEFGHIJKLMNOPQR
    DCBABCDEFGHIJKLMNOPQ
    EDCBABCDEFGHIJKLMNOP
    FEDCBABCDEFGHIJKLMNO
    GFEDCBABCDEFGHIJKLMN
    HGFEDCBABCDEFGHIJKLM
    IHGFEDCBABCDEFGHIJKL
    JIHGFEDCBABCDEFGHIJK
    KJIHGFEDCBABCDEFGHIJ
    LKJIHGFEDCBABCDEFGHI
    MLKJIHGFEDCBABCDEFGH
    NMLKJIHGFEDCBABCDEFG
    ONMLKJIHGFEDCBABCDEF
    PONMLKJIHGFEDCBABCDE
    QPONMLKJIHGFEDCBABCD
    RQPONMLKJIHGFEDCBABC
    SRQPONMLKJIHGFEDCBAB
    TSRQPONMLKJIHGFEDCBA



## 