Characters are really small integers. '0' is a convenient symbol for the value 48. If you add 1 to 48, you get 49. And 49 is the actual value of the character '1'. Because '0' is a symbol for 48, you can say '0'+1 and still get 49. You can take 49 and print it as an int to get 49, or print it as a char to get '1'. Cool, huh? The decimal digits are required to be contiguous, so you end up with this sequence:

Be warned! The only characters that have any kind of order specified by C++ are the characters '0'-'9'. If you try to do something like 'a'+1, it is not guaranteed that the result will be 'b'.

Be warned again! ;) For simplicity I used 48 and 49 as examples of the underlying value for '0' and '1', but that is not guaranteed either. The actual value of a character depends on the character set being used. '0' and '1' are 48 and 49 for the ASCII and Unicode character sets, but there are others out there that do not use the same values, like EBCDIC.

Summary: Characters are small integers, you can do arithmetic on them just like on ints and get a different character in the character set. But C++ does not impose restrictions on character sets beyond making the decimal digits have contiguous values. If you rely on any kind of order for other characters, or the actual value of any character, your code may not work the same way everywhere.

Characters are really small integers. '0' is a convenient symbol for the value 48. If you add 1 to 48, you get 49. And 49 is the actual value of the character '1'. Because '0' is a symbol for 48, you can say '0'+1 and still get 49. You can take 49 and print it as an int to get 49, or print it as a char to get '1'. Cool, huh? The decimal digits are required to be contiguous, so you end up with this sequence:

Very cool! I'm amazed at how much I'm learning through a forum. Thank you times a million!

I'm trying to compare 2 different CSV files, mark those differences respectively, then produce it as an output. However, my code seems to be only reading the last part of ...

I am becoming confused with visual studio v. Vb.net. I am findings hundreds of pieces of code tells me how to connect. Snippets elsewhere that tell me how to access ...