Statistics:Mode (Inheritance)

I have been working on this program all day and I can't get this program to run. After I fix an error I just keep getting new errors. I am trying to call get_Median but I get an error Please can anyone help?:

Mode.h:40: undefined reference to `Mode::Mode()'

Last edited on
You declare a default constructor for Mode, but never define it.
I am newbie. Can you please tell me how to define it?

With all the rest of the code you have, I would think you know how to do that. Unless you just copied the code from somewhere, that is...
This is homework and the professor gave this code to the class so that we can modify it to find the mode, mean, and median. It will be helpful if you can show me how to define Mode.
Thank you.
Do you know how to define a function?
Sorry I don't understand why I need to define Mode().
Last edited on
It's because now that you've declared a class that inherits from Mode, that class needs to call it's base constructor, which you didn't define. It was fine before because it wasn't used.
Do I define Mode() in the Statistics class and how would that look like? I don't know much about inheritance.
Last edited on
Topic archived. No new replies allowed.