返回堆中变量的引用-软件学院C++
                    9.返回堆中变量的引用int &a =new int(2) //error (若不能正确分配内存,new返回NULL值,而引用不能是NULL值) #include #include  using namespace std; int main(){ int *pint =new int(1); if (pint==NULL) { cout                
            
                                        
                                    文件大小:2.25MB
                                
                                
                                
                            
评论区