求助:请大虾指点初次调试简单学习程序的问题
第一次在VC++2010编译调试程序,下面简单的学习程序在VC++2010编译通过(生成成功)
#include <iostream>
using namespace std;
void main(){
char * name;
cout<<"Please input your name";
cin>>name;
cout<<"Hello,"<<name<<"!"<<endl;
};
但运行(启动调试)后,就出现下面对话:
Run-Time Check Failure #3 - The variable 'name' is being used without being initialized
不知如何解决,请大虾指点,谢谢!