This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: FW: why it is not from 0?


Hi Eric,

This is really a question about character sets and string representation
in C and not a question about GCC.

What you are seeing are the integer values of the individual characters
in the array, that is '0' to '8' followed by the string terminator '\0'.
The values, you see, are consistent with with the ASCII character set.

http://en.wikipedia.org/wiki/ASCII

Try changing the string and compare the result with the ASCII tables.

Yours sincerely,

Bjorn


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]