title: iterate over Result returned from mongodb in nodejs
body: <p>I could not able to iterate through Result returned from mongodb</p>
  
  <p>Here is code that connect to mongodb and gets the result</p>
  
  <pre><code>MongoClient.connect(url, function (err, db) {       
  
          var collection = db.collection('users');            
  
              collection.remove({}, { w: 1 }, function (err, result) {
                      console.log(result.ok);
                      res.json    ({ success: true, obj:result.ok});                    
              })
  });
  </code></pre>
  
  <p>the result is</p>
  
  <pre><code>obj: {ok: 1,n: 0}
  </code></pre>
  
  <p>I am getting undefined when i tried to access the value of <strong>n</strong> using <strong>result.n</strong>.</p>
  
  <p>Could anyone let me know the way to access the values of returned result in nodejs</p>
  
  <p>Thanks</p>