求教哪里错了
#include "stdio.h"class Reader{
private:
char Name;
int ID;
char Priority;
public:
Reader(char* x="",int y=0,char* z=""){Name=*x;ID=y;Priority=*z;}
char GetName(){return Name;}
int GetID(){return ID;}
char GetPriority(){return Priority;}
};
void main()
{
Reader reader1("小明",2014110131,"学生");
printf("%c\n%ld\n%c\n",reader1.GetName(),reader1.GetID(),reader1.GetPriority());
}
结果是
?
2014110131
?
求教下哪里错了