class tower
{
private:
stack* zone[3];
int pos;
public:
int move(tower& to);
int check();
tower(int a);
~tower();
};
tower::tower(int a)
{
pos=a;
zone[3]=new stack(5);
}
int tower::move(tower& to)
{
int data_from,data_to;
if(this->zone->pop(data_from))
{
}
else cut<<"cant pop data at From tower.";
}
인데 if(this->zone->pop(data_from))에서 자꾸 오류가 나네
request for member 'pop' in '*(stack**)(&((tower*)this)->tower::zone)', which is of pointer type 'stack*' (maybe you meant to use '->' ?)
에러문은 난해해서 뭔지도 모르겠고.. 살려줘..
댓글 0