SyntaxFix
Write A Post
Hire A Developer
Questions
int val = '1' - '0';
This can be done using ascii codes where '0' is the lowest and the number characters count up from there