0
Array
in an array b[]={1,2,3,4,5}, when we assign new value suppose b[2]=10; then would it replace 3 by 10 or create an array with values {1,2,10,3,4,5}. similarly if in array b[5]={1,2,3,4,5}, b[2]=10; is assigned, what would happen?
1 ответ
+ 11
In both cases, it will only replace the element at the given index, in your case 2, and not create a new separate array everytime. 😇