How can you increase the size of a statically allocated array?
Answer / Parul Sonker
A statically allocated array cannot be resized during runtime. If you need to store more values than the initial capacity, consider using a dynamically allocated array or another data structure.
| Is This Answer Correct ? | 0 Yes | 0 No |
#define swap1(a,b) a=a+b;b=a-b;a=a-b; main() { int x=5,y=10; swap1(x,y); printf("%d %d\n",x,y); swap2(x,y); printf("%d %d\n",x,y); } int swap2(int a,int b) { int temp; temp=a; b=a; a=temp; return; } what are the outputs?
What is the benefit of using const for declaring constants?
I have a varargs function which accepts a float parameter?
change to postfix a/(b+c*d-e)
How can I dynamically allocate arrays?
identify the in correct expression a.a=b=3=4; b.a=b=c=d=0; float a=int b=3.5; d.int a; float b; a=b=3.5;
Explain Function Pointer?
there is two conditions , 1. while using for loop for printing 1 to 50 no's simulteneous 2. while using printf functios for printing 1 to 50 no's simulteneous with or without using variables who will take more time for compiling and execution? explain in details with reason?
In c programming typeing to occupy the variables in memory space. if not useing the variable the memory space is wasted.ok, how to avoid the situation..? (the variable is used & notused)
Give the output for the following program. #define STYLE1 char main() { typedef char STYLE2; STYLE1 x; STYLE2 y; clrscr(); x=255; y=255; printf("%d %d\n",x,y); }
What is page thrashing?
what is difference between declaring the pointer as int and char in c language?