Search:

Type: Posts; User: EDale

Search: Search took 0.08 seconds.

  1. Replies
    11
    Views
    1,992

    [SOLVED] Re: Inheritance constructor help?

    Well I figured it out. I had to call super to get the name and age from the super class. Then since boolean perryComoFan is private, I couldn't refer to it directly.



    Public Oldie(String n, int...
  2. Replies
    11
    Views
    1,992

    [SOLVED] Re: Inheritance constructor help?

    The compiler we use for our class is called OWL, it is a part of our online textbook created by UMass Amherst I believe. If I enter the correct code, it marks my question correct and I can move on....
  3. Replies
    11
    Views
    1,992

    [SOLVED] Re: Inheritance constructor help?

    That was my fault, I typed it here with a capital P but in my code it is lowercase.
  4. Replies
    11
    Views
    1,992

    [SOLVED] Re: Inheritance constructor help?

    So I changed the code to :



    public Person(String n, int a, boolean p) {
    this.name=n;
    this.age=a;
    perryComoFan=p;
    }
  5. Replies
    11
    Views
    1,992

    [SOLVED] Re: Inheritance constructor help?

    Here is the error message:

    compilation error (line 2, column 42) cannot find symbol
    symbol : constructor Person()
    compilation error (line 3, column 7) name has private access in...
  6. Replies
    11
    Views
    1,992

    [SOLVED] Inheritance constructor help?

    Here is the question:

    The Person class has two attributes, name and age. We want to create a subclass of Person, called Oldie, that represents someone who is getting on in age, say about thirty...
Results 1 to 6 of 6