0
How the value gets same after increment
C ,auto variables topic
4 ответов
+ 3
Ajith
Because you didn't initialised bj that's why 99 is assigned to bj. If you initialised bj with value then you will not get that.
+ 1
Tq aj
0
#include<stdio.h>
int ajit()
{
int aj;
printf("%d\n",aj);
aj=99;
printf(%d\n,aj);
}
int bji()
{
int bj;
printf("%d\n",bj);
bj++;
printf("%d\n",bj);
}
int main()
ajit();
bji();
return 0;
}
Final output is 0 99 99 100
0
How values are getting allocated to bj ..help me wizards