Not able to replicate the code

when i am trying to repeat the code for the static allocation part, I am not able to return the address and neither the junk value is printing which is in case in problem described in the video.
the code is this :

#include
using namespace std;
int *fun(){
int a[]= {1,2,3,4,5} ;

cout<<a<<endl;
cout<<a[0]<<endl;
return a;

}
int main(){
int *b = fun();
cout<<b<<endl;
cout<<b[0]<<endl;
return 0;
}

Please share your code using ide.codingblocks.com