c is a charater declaration. so anything that gets into c will be character.Quote:
Originally Posted by Sephiroth
if c = '1' , ascii value of character '1' is 49 so c = 49 too.
c = '1', in [c-'0'] c's ascii value will be subratted to the ascii value of charcter '0' which will yeild the diff of 1.
get the point?
ascii values:
'0' = 48
'1' = 49
'2' = 50
so on...