Got a question I don't understand, can anyone make sense of it?
<p>Question from an online resource paper:</p>

<pre><code>Create javascript so that the following methods 
produce the output listed next to them.

    circle = new Circle();
    console.log(circle.get_area());  // 3.141592653589793
    circle.set_radius(10);
    console.log(circle.get_area());  // 314.1592653589793
    console.log(circle);             // the radius of my circle is 10 and its area is 314.1592653589793
</code></pre>

<p>Can anyone understand what is being asked?</p>

<p>Here is a copy of my comment below in pretty format:</p>

<pre><code>function Circle() {
    this.pi=3.141592653589793;
    this.radius;
}  

Circle.prototype={
    get_area: function(){
        return this.radius*this.pi;
    },
    set_radius: function(radius){  
        return this.radius=radius;
    }  
};  

circle=new Circle();
circle.set_radius(100);
</code></pre>

<p>Okay I've played around with this and kind of get the gist of what is happening, although I'm unsure as to when or why one would need to write in this technique; if someone could explain I'd perhaps have a better understanding of its uses.</p>

<p>My final code is as follow: -</p>

<pre><code>function Circle(r) {
    this.pi=Math.PI;
}  

Circle.prototype={
    get_area: function(){
        return this.radius*this.pi;
    },
    set_radius: function(radius){  
        return this.radius=radius;
    }
};  

var circle=new Circle();
circle.set_radius(100);

Circle.prototype.toString=function(){
    return 'The radius of my circle is '+circle.radius+' and it\'s area is '+this.get_area();
}

console.log(circle);
</code></pre>

<p>I'm not entirely sure if I'm using Circle.prototype.toString=function() correctly as all it seems to do is create a string.</p>
