+ 1
Replace elements in 2d array
in java: how do i replace an element in a 2d array. im trying to just reassign but it doesnt seem to be working. maybe its just another part of my code thats not correct but im not sure. can someone help please Its a char array in case that helps Link: repl.it/@noup/arraysTICTAC
4 Respostas
+ 1
int[][] myarr = {{1,2,3},{4,5,6}};
// now change the 3 to 10
myarr[0][2] = 10;
// now change the 5 to 10
myarr[1][1] = 10;
+ 1
Link: repl.it/@noup/arraysTICTAC