Class Snake
java.lang.Object
|
+--Animal
|
+--Snake
- public class Snake
- extends Animal
Class Snake - write a description of the class here
Constructor Summary |
Snake(double length)
Constructor for objects of class Snake |
Methods inherited from class java.lang.Object |
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Snake
public Snake(double length)
- Constructor for objects of class Snake
- Parameters:
length
- (in meters)
move
public String move()
- move method
- Overrides:
move
in class Animal
- Returns:
- a text description of the motion
toString
public String toString()
- toString method
- Overrides:
toString
in class Object
- Returns:
- a String representation of the Human
Generated by BlueJ