how to declare class::function in the header file(plz. read)

Hi I want to solve this main function with a different class, I somehow know how to do it but the problem is that how to call

1
2
3
4
5
int main() {
   Matrix m1{{1, 2, 3}, //
              {4, 5, 6}};
    Vector v1 = linalg::gaussElimination(m1); // how do i call it in a class function?
}


if i know how to call this function then i might know how to solve it
Last edited on
? Either you have it or you don't have it. Do you have the class with the function coded? Did you put it in a header file? Did you #include the header file in the cpp?

Your question is a tad vague.

If you have the class and you can call it from int main() while the class is in the cpp, then simply move the class to a header file then #include it and call it.
Nah I assigned the static keyword from the net sorry...
Last edited on
Topic archived. No new replies allowed.