I am trying to match (a) and replace (b) the following occurrences:
array[0] -> atoi(array[0])
array[1] -> atoi(array[1])
...
array[i+1] -> atoi(array[i+1])
and so on…
(a) I am unable to match anything with the following expression array\\[(.\*?)\\] , array\\[.\*?\\] , or array\\[*\\]
I am able to match single character occurrences between the brackets with array\\[.\\] and additionally also segments with multiples matches on a single line with array\\[.*\\]
(b) After a working match I figure s/"MATCHING REGEX"/atoi(array\[\1\])/g should work, however attempting that with array\\[.\\] resulted in atoi(array[])
How about this?