C Programming - Declarations and Initializations - Discussion

Discussion Forum : Declarations and Initializations - General Questions (Q.No. 9)
9.
Identify which of the following are declarations
1 : extern int x;
2 : float square ( float x ) { ... }
3 : double pow(double, double);
1
2
1 and 3
3
Answer: Option
Explanation:
extern int x; - is an external variable declaration.

double pow(double, double); - is a function prototype declaration.

Therefore, 1 and 3 are declarations. 2 is definition.
Discussion:
37 comments Page 4 of 4.

Divya said:   1 decade ago
Float x; is a declaration.

Nivu said:   6 years ago
Thanks all for explaining.

Swathi bhat said:   1 decade ago
What does double pow mean?

Vani said:   8 years ago
Nice explanation @Sundar.

Surya said:   1 decade ago
Nice explanation Sundar.

Dhruv said:   1 decade ago
What the extern work ?

Shradha said:   1 decade ago
What is extern?


Post your comments here:

Your comments will be displayed after verification.