What's wrong with this code ?
----------Animal.java----------
public class Animal
{
private String type;
public Animal( String atype)
{
type= atype;
}
public void show()
{
System.out.println("This is a " + type);
}
}
----------------dog.java----------
public class Dog extends Animal
{
private String name;
private String breed;
public Dog (String name,String breed);
{
super("Dog");
name= name;
breed= breed;
}
public Dog(String name)
{
super("Dog");
name = name;
breed ="unknown";
}
}
------------------TestAnimal---------------
public class TestAnimal
{
public static void main(String args[])
{
Dog a = new Dog("Lassie");
Dog a1 = new Dog("Fido","Chihuahua");
a.show();
a1.show();
}
}
------------------------------