samedi 27 juin 2015

how to get an integer from a char array

I have a char array that has '4''5'. But I want to convert those characters into actual integers so I subtract '0' from each index of the char array and store it into the same array. If I want to set an int called value to the 45 (the stuff inside the char array) How would I do it?

Aucun commentaire:

Enregistrer un commentaire