TCLUG Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [TCLUG:10678] Simple C Question



Brian Ackermann wrote:
> 
> Ok, simple question for all you C programmers out there...
> 
> Here's the line of code in question...
> 
> printf("%s\n", (char *)(FO_Offset+=16));

Hmm.. looks to me like this would output the ASCII characters with the
values 16, 32, etc., instead of the strings '16', '32', etc..

Will what I have below work (I'm a bit rusty WRT C)?

printf("%d\n", FO_Offset+=16);

The "%d" means that the following value is an integer of some kind.

-- 
 _  _  _  _ _  ___    _ _  _  ___ _ _  __   Who is "they" anyway? 
/ \/ \(_)| ' // ._\  / - \(_)/ ./| ' /(__                              
\_||_/|_||_|_\\___/  \_-_/|_|\__\|_|_\ __)                             
 [ Mike Hicks | http://umn.edu/~hick0088/ | mailto:hick0088@umn.edu ]