I have an array that is char and all of them are numbers but in type of Char means:

```
myArray = ['5','6','8','9','10',....]

```

for example i wnat to add two of them.i must to convert them to integer and then add them together but using:

```
(int)myArray[1]+(int)myArray[2]

```

give a wrong answer.
what is the function or the correct way for doing this?