Ok guys so please dont answer this if you dont know houw pointers work, as you w
ID: 3554570 • Letter: O
Question
Ok guys so please dont answer this if you dont know houw pointers work, as you will not be able to help me. I have a double class pointer delcared in my main(pointer to an array of pointers to instances of the class) then I Pass it by refence to a function to add data and it works. After that back in the main I pass the same way to another function, which inturn passes it to another function the same way I passed it in the main (CLass** &name). Then that function calls a class function on one of the instances of the class I have in the double pointer which uses other instances in the double pointer. I did this by passing (index1,index2,Class** &name), but when it finishes it appears not to have applied the changes invoked by the class function. Ask any questions u want. No I will not pay you to look at my code, I am in school to learn it myself.
Explanation / Answer
//main List** Class1;
file(argv,Class1);//data is copied to class here and it works
b=bellham(Class1);//bellham takes as class** &class
relax(cr,co, class); //relax takes class** &class
class[y]->classfunction(1,2,3,4,class); //classfunction takes as class** &class
The way you have tried to access the member function and passing the double pointer are all fine. I don't see a glitch there. It must be something else that's troubling you. As you are passing by reference everywhere, changes should have reflected.
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.