index.js
//Draw function in p5.js to draw the project. 

Draw function in p5.js to draw the project.
Draw function in p5 . js to draw the project .
function draw() {
    background(51);
    prey.paintFood();
    prey.update();
    snake.terminate();
    snake.update();
    snake.show();
    if(snake.eat(food)) {
        snake.scoreCard();
        pickLocation(); 
    }
}
function draw ( ) { background ( 51 ) ; prey . paintFood ( ) ; prey . update ( ) ; snake . terminate ( ) ; snake . update ( ) ; snake . show ( ) ; if ( snake . eat ( food ) ) { snake . scoreCard ( ) ; pickLocation ( ) ; } }
Draw function in p5.js to draw the project.
Draw function in p5 . js to draw the project .
//Draw the prey (or) food.
 //Call update function of prey Object.
 //Check for the termination scenario.
 //call the functions
 //call the eat function.
