6 years ago in C Basic Concepts

# Is it true that a global variable may have several declarations, but only one definition?

[A] Yes
[B] No

Create your Digital Resume For FREE on your name's sub domain "yourname.wcard.io". Register Here!

## Overall Stats

Attempted 121
Correct 33
Incorrect 37
Viewed 51

Deep - 1 year ago

Deep from Kolkata, India is saying Yes is correct answer

indhuja indhuja - 1 year ago

indhuja indhuja from Erode, India is saying No is correct answer

Sidharth kashyap - 1 year ago

Sidharth kashyap from Patna, India is saying Yes is correct answer

R.K YouTube channel - 1 year ago

R.K YouTube channel from Bhubaneswar, India is saying Yes is correct answer

Rajeswari Raji - 1 year ago

Rajeswari Raji from Hyderabad, India is saying Yes is correct answer

## Related Questions

• [A] Yes
• [B] No

### In the following program where is the variable a getting defined and where it is getting declared? #include int main() { extern int a; printf("%d\n", a); return 0; } int a=20;

• [A] extern int a is declaration, int a = 20 is the definition
• [B] int a = 20 is declaration, extern int a is the definition
• [C] int a = 20 is definition, a is not defined
• [D] a is declared, a is not defined

### How would you round off a value from 1.66 to 2.0?

• [A] ceil(1.66)
• [B] floor(1.66)
• [C] roundup(1.66)
• [D] roundto(1.66)

### Is there any difference between following declarations? 1 : extern int fun(); 2 : int fun();

• [A] Both are identical
• [B] No difference, except extern int fun(); is probably in another file
• [C] int fun(); is overrided with extern int fun();
• [D] None of these

### By default a real number is treated as a

• [A] float
• [B] double
• [C] long double
• [D] far double