Biology Forums - Study Force

Science-Related Homework Help Computer Studies Topic started by: Eels on Dec 16, 2016



Title: Look at the following code and determine what the call to super will do.public class ClassB extends ...
Post by: Eels on Dec 16, 2016
Look at the following code and determine what the call to super will do.

public class ClassB extends ClassA
{
  public ClassB()
  {
    super(10);
  }
}

A) This cannot be determined form the  code.
B) It will call the method super and pass the value 40 to it as an argument.
C) The method super will have to be defined before we can say what will happen.
D) It will call the constructor of ClassA that receives an integer as an argument.


Title: Re: Look at the following code and determine what the call to super will do.public class ClassB ...
Post by: blithering on Dec 18, 2016
Content hidden


Title: Re: Look at the following code and determine what the call to super will do.public class ClassB extends ...
Post by: Eels on Jan 31, 2017
YOU'RE AWESOME