what is the difference between declaration ,defenetion and
initialization of a variable?
Answer Posted / shabeer v c
A good example to illustrate this Question ges like this:
Whenever we apply for a job the company declares that we
have been selected. Similarly we declare a variable like
int emp;
(here emp behaves as an employee).
Then he will be assigned with a initial salary which
will be incremented in course of time period or on
experience basis.
Similarly the variable int is assigned a initial
value.
i.e int emp=20;
(value can be changed in between program)
The employee is now identified by his post, which can
define his status in the company.
Same way the variable is also defined in the
program.
ie. int emp;
| Is This Answer Correct ? | 16 Yes | 3 No |
Post New Answer View All Answers
Explain Function Pointer?
What is the explanation for the dangling pointer in c?
How can I delete a file?
What is the role of this pointer?
What are pragmas and what are they good for?
How a string is stored in c?
What is printf () in c?
What is pointer to pointer in c?
What is the heap?
Write a program to swap two numbers without using a temporary variable?
Add Two Numbers Without Using the Addition Operator
What is difference between function overloading and operator overloading?
What is the purpose of scanf() and printf() functions?
What is ctrl c called?
What is c++ used for today?