void LList::Menu(){
//This displays the vigesimal number that is current. then ask
//for a user input.
char useranswer;
int answer;
answer=0;
cout<<"Current vigesmial number is: ";
Print();
cout<<endl;
cout<<endl;
cout<<"Command (h for help) : ";
useranswer=Read_element();
answer=useranswer;
if ((answer == 101) || (answer == 69))
Vigesimalinput();
elseif ((answer == 97) || (answer == 65 ))
AddVigesimal();
elseif ((answer == 109) || (answer == 77 ))
MultiplyVigesimal();
elseif ((answer == 104) || (answer == 72))
HelpMenu();
elseif ((answer == 113) || (answer == 81))
Menu();
else
cout<<"Invalid menu option (h for help)""\n"<<endl;
Menu();
}
then in my print() i'm totally dropping the ball
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
void LList::Print(){
//Pre; The N.O LList is valid
//Post: the N.O LList is unchaged and its elements have been
// displayed
char letter;
int val;
listnode* temp;
temp=head;
while(temp != NULL){
temp=val;
temp=letter;
cout<<temp -> data;
temp=temp -> next; //pointer increament
}
}
so my head wanted to just use temp=letter
but since temp is a listnode* and not an int it does not convert