프로그래밍/C/C++
Single char to int
halloRa
2012. 3. 15. 21:35
char a = '1';
int b = a -'0';
출처: http://stackoverflow.com/questions/439573/how-to-convert-a-single-char-into-an-int
int b = a -'0';
출처: http://stackoverflow.com/questions/439573/how-to-convert-a-single-char-into-an-int