Hello all
i tried the following code and got unexpected outputs.
can anyone provide me with any feedback on any mistake that i have done.
Code:#include<iostream.h> #include<stdio.h> void stm() { cout<<"hello"; } struct a { stm(); }b; main() { cout<<endl<<b.stm(); cout<<endl<<sizeof(b)<<endl; stm(); return(0); }
output :
[
it do not compiles why ?
and on commenting the first cout it gives the value 1.