关于一段代码的问题
程序代码:
#include<stdio.h> #include<iostream> using namespace std; void fun(){ char *p=NULL; p=new char[5]; p=(char*)0x00000061; cout<<*p<<endl; delete p; } void main(){ fun(); cin.get(); getchar(); return; }
#include<stdio.h> #include<iostream> using namespace std; void fun(){ char *p=NULL; p=new char[5]; p=(char*)0x00000061; cout<<*p<<endl; delete p; } void main(){ fun(); cin.get(); getchar(); return; }