My problem is that I want to call an array from one function in a header file and then input it into another function in the header file. For example consider the code.
Class MyExample{
private:
double Array1[16], a, b;
int n;
public:
double function1(int n);
double function 2();
};
MyExample::function1(n){
for(a=0;a
Array1[n] = a;
}
}
MyExample::function 2(){
//I need to get Array1[n] into this function!
for(a=0;a
Array1[n] = Array1[n]/b;
}
/*
Whats more is that I want to be able to have Array1[n] not be converted to a int because n is an integer.
Also then how would I return Array1[n] to the .c++ file?
Thanks, any help is appreciated as it is getting a bit irritating since I just can't pass the thing.
Brian
*/
2006-07-28
04:48:51
·
3 answers
·
asked by
Brian D
1
in
Computers & Internet
➔ Programming & Design