-3
9行9列の配列を表示したい。 セルをクリック可能にする必要があります。2次元配列のAndroidスタジオレイアウト
Javaではかなりシンプルです。
Android Studioではどのレイアウトを使用しますか?この実装する2つの方法があり
int myArray[][] = new int [9][9]; // Previously filled with random numbers.
for (int i = 0; i < myArray.length; i++){
for (int j = 0; j < myArray[i].length; j++) {
System.out.print(" " + myArray[i][j]);
}
System.out.println("");
}
GridLayoutManagerでRecyclerViewを使用することができます –
ありがとうございます。私はそれを行います。 –