Search:

Type: Posts; User: thebenman

Search: Search took 0.07 seconds.

  1. Replies
    5
    Views
    830

    Re: Help with Inheritance in Java.

    Thanks a lot.Is it mandatory for all the executable statements to be inside a constructor or method ? unlike in C/C++ ? I did put all the executable statements inside the constructor for car class.
    ...
  2. Replies
    5
    Views
    830

    Re: Help with Inheritance in Java.

    I'll keep the naming convention in mind the next time :)

    The errors from car.java
    D:\java>javac car.java
    car.java:4: error: <identifier> expected
    System.out.println("Enter the number of...
  3. Replies
    5
    Views
    830

    Help with Inheritance in Java.

    hey i was leaning inheritance and tried to implement it in Java.This is my base class vehicl.java
    public class vehicle{
    private int topSpeed;
    private int cubicCap;
    private String modelName;...
Results 1 to 3 of 3