Loading...

algogeeks@googlegroups.com

[Prev] Thread [Next]  |  [Prev] Date [Next]

Re: [algogeeks] Re: difference b/w static global variables and global variables Ashish Goel Mon Feb 27 17:00:18 2012

then how static can be an extern?
Best Regards
Ashish Goel
"Think positive and find fuel in failure"
+919985813081
+919966006652


On Mon, Feb 27, 2012 at 10:50 PM, teja bala <[EMAIL PROTECTED]>wrote:

> As we all know about data organisation structure in c like stack area,heap
> area and un intialized data segment ....
>
> so wen uninitialized global variable will be allocated memory in
> unitialized data segment but static variable ll be local to entire
> file,initialized to 0 and kept in heap area mostly but if any recursive
> calls associated with dat particular variable den stack segment is
> used......
>
> hope it xplains....
>
> Regards,
> MOZHI.
>
> On Mon, Feb 27, 2012 at 8:46 PM, Don <[EMAIL PROTECTED]> wrote:
>
>> In addition to the difference in scope, the standard requires that
>> static variables be initialized to zero by default. Global variables
>> are not required to be initialized by default.
>> Don
>>
>> On Feb 25, 10:51 am, AMAN AGARWAL <[EMAIL PROTECTED]> wrote:
>> > Hi ,
>> >
>> > Is there any difference b/w static global variables and global
>> variables ???
>> >
>> > (apart from that static variables will be limited to that file only and
>> > global variables will be visible for other files also.)
>> >
>> > Regards,
>> > Aman.
>> >
>> > --
>> > AMAN AGARWAL
>> > "Success is not final, Failure is not fatal: It is the courage to
>> continue
>> > that counts!"
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to [EMAIL PROTECTED]
>> To unsubscribe from this group, send email to
>> [EMAIL PROTECTED]
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to [EMAIL PROTECTED]
> To unsubscribe from this group, send email to
> [EMAIL PROTECTED]
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to [EMAIL PROTECTED]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.