title: Adding numbers in an object is not working as expected in JS
body: <p>I created an object with Int values and some functions in js as below</p>
  
  <pre><code>var obj = function (int1,int2,int3){
    this.int1=int1;
  this.int2=int2;
  this.int3=int3;
  this.add= (function (){
  return parseInt(int1)+parseInt(int2)+parseInt(int3)
  }());
  </code></pre>
  
  <p>When I execute the code</p>
  
  <pre><code>var a= new obj(1,2,3);
  console.log(a.add);
  </code></pre>
  
  <p>The Answer is </p>
  
  <blockquote>
    <p>NaN</p>
  </blockquote>
  
  <p>Type of all the int1,int2.int3,add is Number.
  <strong>Whats the problem with My code &amp; How to correct it</strong></p>