Answer Posted / vinod
C99 and above supports the conceptof VLA(Variable Length Array) which allows you to set array size based on input during run time. It can also done using dynamic memory allocation.
Example:
int main()
{
int i;
scanf("%d",&i);
int a[i];
}
Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
What are the string functions? List some string functions available in c.
What is printf () in c?
What are pointers? What are stacks and queues?
what is associativity explain what is the precidence for * and & , * and ++ how the folloing declaration work 1) *&p; 2) *p++;
What is fflush() function?
What is declaration and definition in c?
find the output? void r(int a[],int c, int n) { if(c>n) { a[c]=a[c]+c; r(a,++c,n); r(a,++c,n); } } int main() { int i,a[5]={0}; r(a,0,5); for(i=0;i<5;i++) printf("\n %d",a[i]); getch(); }
What is a volatile keyword in c?
How can a program be made to print the line number where an error occurs?
Write a C program in Fibonacci series.
Explain what is wrong with this statement? Myname = ?robin?;
how we can make 3d venturing graphics on outer interface
Compare and contrast compilers from interpreters.
What are the complete rules for header file searching?
while loop contains parts a) initialisation, evalution of an expression,increment /decrement b) initialisation, increment/decrement c) condition evalution d) none of the above