This question already has an answer here:
- How to convert a single char into an int 7 answers
I came across a C code snippet which had a statement s[*num - '0'] where both s and num are character pointers.
I would like to know what will actually happen if we use *char-'0' as the index of a pointer.
Aucun commentaire:
Enregistrer un commentaire