【发布时间】:2021-05-11 14:24:03
【问题描述】:
或矩阵,我想在“cmap”中拟合“map”二维数组,该数组大+2,实际上我想使用“cmap”作为“map”的框架,但我想不使用单个数组(也因为我想在“map”二维数组中随机生成字符...您有什么建议吗?
rows, cols = (9, 9)
crows, ccols = (rows + 2, cols + 2)
print(crows, ccols)
cmap = [["#" for x in range(crows)] for y in range(ccols)]
map = [["#" for x in range(rows)] for y in range(cols)]
【问题讨论】:
-
您能说明一下您要做什么吗?我无法理解您的解释;您所展示的内容如何无法提供您所说的内容? How to Ask
-
看这张照片imgur.com/a/f0iP8tj,我正在尝试将红色二维数组插入绿色数组中
标签: python python-3.x matrix multidimensional-array character