can anyone see why this code isnt working?
while(array[i][j] != '?')//while not end of array
//invariant: array[i][j] is not a question mark and array[i][j] is part of an array
temp = new StackFrame;
temp->data = array[i];
temp->link = top;
top = temp;
What kind of erros are u getting?? Compile-time or runtime??? What line???
At a first glance this doesn´t seem to be right
while(array[i][j] != '?')//2D-Array
Need to see more code to solve this error (and know what kind of error it is).
temp->data = array[i];//Now 1D-Array???
Also read this before replying
There is a design error in your code. Array never gets updated.
its a run time error.......i'm trying to input an array into a linked list. i dont think it has anything to do with changing it fropm a 2 to a 1 dimensiona array because it works when i just have the while loop do this......
cout << array[i];
what do you mean the array never gets updated?
if i make this linked list in a while statement, can i still access it outside the while statement?
never mind.......i'm an idiot and figured it out. i had a null as the last place in the linked list and when i was tested it i was only outputting the top->data which was a null and didnt output anything.