In the following code, first letter of a string in array at index 0
does not gets replaced by the uppercase value although you can access the first letter with arr[0][0]
. Why?
var arr = ["mangoes","orange","apple"];
arr[0][0] = arr[0][0].toUpperCase();
arr;
thanks bt