void main()
{
int a[]={1,2,3,4,5},i;
for(i=0;i<5;i++)
printf("%d",a++);
getch();
}
Answer Posted / chhaya
Here , in program array is given of 5 element. But at d
time of printing output ,increase address not pointer
i.e.
a[i]={1,2,3,4,5}
then u wnat to print array
Printf("%d",i++);
getch();
this sentence is requird. because array is set of element
and element is pointed by "pointer". If u wnt to show
element then use pointer not address of array.....
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Why is c not oop?
Explain how can I avoid the abort, retry, fail messages?
Tell me can the size of an array be declared at runtime?
What is use of bit field?
we called a function and passed something do it we have always passed the "values" of variables to the called function. such functions calles are called a) calls by reference b) calls by value c) calls by zero d) none of the above
What is the g value paradox?
Can we increase size of array in c?
Why doesnt this code work?
What is operator precedence?
what do you mean by inline function in C?
How to declare a variable?
Explain how can I convert a number to a string?
Simplify the program segment if X = B then C ← true else C ← false
What are the types of assignment statements?
given post order,in order construct the corresponding binary tree