In 1, the ASCII value of 2 is 50 and the ASCII value of 3 is 51 so if you add it up, it's 101 and the ASCII character corresponding to 101 is e, so I understand that e came out.
In 2, there was no text corresponding to the Aski value of 53 and just 5 came out, so I'm asking why.c++
The ASCII code value for
'2' is 50 and the ASCII code value for
'5' is 53.
'2' + 3 will be 55. You used
printf() so the character
'5' for 55 was printed.
Try the following:
© 2022 pinfo. All rights reserved.