Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Difference between static global and global?

Answer Posted / sheela

hello...

what r all above said is false. global static also can
access using extern in other files.

file 1:

#include<stdio.h>
#include <conio.h>
#include "file2.c"
int a=10;
static int b=20;
main()
{
send();
}


file 2:


#include<stdio.h>
#include<conio.h>

void send()
{
extern int a;
extern int b;
printf("%d%d",a,b);
getch();
}


this program prints both a and b values.. then how can u
say global statics has file scope.

please if anybody knows correct answer give me.

Is This Answer Correct ?    0 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How can you create a virtual copy constructor?

1090


Describe the advantage of an external iterator.

1042


Explain rethrowing exceptions with an example?

1028


What flag means?

962


Do the parentheses after the type name make a difference with new?

1093


What does std mean in c++?

1132


What causes a runtime error c++?

1130


what are the decision making statements in C++? Explain if statement with an example?

1099


How would you use the functions sin(), pow(), sqrt()?

1190


What is the best free c++ compiler for windows?

1112


What is meant by forward referencing and when should it be used?

1021


Specify some guidelines that should be followed while overloading operators?

1213


Write a program to find the Factorial of a number

1064


What is a flag in c++?

1063


What are c++ manipulators?

1080