Skip to content

piyush8188/get-set-animals-piyush8188

Repository files navigation

Get Set Animals

Create a class called Animal that has a constructor method that takes one argument: species. It should have a getter for species and a method called makeSound() that logs a sound the animal makes. Create a subclass called Cat that extends the Animal class. Add a method to the Cat class called purr() that logs purr to the console. Create a subclass called Dog that extends the Animal class. Add a method to the Dog class called bark() that logs woof to the console.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •