I have followed the instructions as in the object building practice page.
When i define the draw(),
draw(){
ctx.beginPath();
ctx.fillStyle= this.color;
ctx.arc(this.x,this.y,this.size,0,2*Math.PI);
ctx.fill();
}
The abovecode is showing me error near the draw(){ saying β;β expected, I m not knowing how to resolve this.
Shall I mention function draw()?
mikoMK
(Michael Koch)
2
Hi @vaishnavi_A.N
Without more code I can only guess. Maybe you placed the function at the wrong spot. It should go after the constructor but still inside the class.
If this doesnβt help, you should put your whole code into an online editor and I will have a closer look. 
Have a nice day,
Michael
2 Likes
Amazing, it worked, Thank u @mikoMK, how did u gain this much proficiency, I previously placed the code outside the class, Thank u again miko.
1 Like