To start this assignment, open thescript.jsfile in your editor and read through the notes left in the comments. You will be filling in the code based on the comments in this file.
script.js
Some things to keep in mind:
Your rabbits should be named "Rabbit 1" through "Rabbit 4"; this will make it easier when you're coding.
getRandomSpeed
Math.random()
In the Animal class:
run
'Cannot supply rabbit with negative speed.'
Follow the rest of the notes in thescript.jsfile to fill in the contents of the file.
Note:HTML and CSS file is ready , only the javascript needs to be done.
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here