Hi Pradeep,

Yes, it prints the address of the symbol x.

But there is something more here. &x returns an Unsigned integer, but here
the returned valuewill be treated as Signed integer(%d) and printed.
Remember range of Signed integer is ( -32627...32628 ) and Unsigned integer
is ( 0.....65524 ). I don't remember exact ranges but something around that.
Now, if the return value exceeds 32628 then it starts counting from -32627,
-32626..... and so on.

Example if return value is 65476   printed value is -12.

If you use %u then u will get to know this. Try this statement

printf("%u..........%d", &x, &x);



Rgds,
JayaRamesh



   Date: Thu, 02 Dec 2004 10:19:25 +0530
   From: Joe Steeve <[EMAIL PROTECTED]>
Subject: Re: Help!!

"pradeepkumar  jagadeeswaran" <[EMAIL PROTECTED]> writes:
> � I wanted to know how the printf("%d",&x); works.

It prints the address of the symbol x.





------------------------ Yahoo! Groups Sponsor --------------------~--> 
Make a clean sweep of pop-up ads. Yahoo! Companion Toolbar.
Now with Pop-Up Blocker. Get it for free!
http://us.click.yahoo.com/L5YrjA/eSIIAA/yQLSAA/EbFolB/TM
--------------------------------------------------------------------~-> 

To unsubscribe : [EMAIL PROTECTED]

 
Yahoo! Groups Links

<*> To reply to this message, go to:
    
http://groups.yahoo.com/group/Programmers-Town/post?act=reply&messageNum=4156
    Please do not reply to this message via email. More information here:
    http://help.yahoo.com/help/us/groups/messages/messages-23.html

<*> To visit your group on the web, go to:  
    http://groups.yahoo.com/group/Programmers-Town/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to