我正在使用Tkinter进行Python的GUI编程。 我想定义一个多维数组。我尝试了以下代码,但它显示错误。
subMenu =[sub1[],sub2[],sub3[],sub4[],sub5[]]
sub1 = ["New File","Save File","Edit File","Open File","Exit"]
sub2 = ["Undo","Redo","Cut","Copy","Paste"]
sub3 = ["Run","Check Module","Debug","compile","Close"]
sub4 = ["Undo","Redo","Cut","Copy","Paste"]
sub5 = ["Undo","Redo","Cut","Copy","Paste"]
如何在Python中定义多维数组?