Skip to content

Instantly share code, notes, and snippets.

@skiabox skiabox/
Created Oct 12, 2016

What would you like to do?
Wolf class
package com.skiabox.java_apps2;
* Created by administrator on 10/10/2016.
public class Wolf extends Canine{
public void makeNoise() {
System.out.println("The wolf howls");
public void eat() {
System.out.println("The wolf is eating " + Food.MEAT);
//We can override a method from a superclass and at the same time call it like this
public void roam()
System.out.println(", and now that it is a wolf it is very dangerous for its prey");
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.