Here is a program in C language that simply displays variables that have not been initialized,
#include <stdio.h>
int main()
{
int a, b;
printf("%d%d",a,b);
return 0;
}
Output: 00
I have started learning c programming 20 minutes ago for the first time in my life, can you tell me why does it show the output as 00, now since we're supposed to initialize out variables with 0 in most cases to avoid seeing the garbage value in their place so I just wanted to know why does it happen ? Why don't we get a garbage value instead and not the plain '0' which has its own ASCII value?