title: In which order these code statements are moved to call stack?
body: <p>I am new to Javascript and trying to understand the execution engine of JS. I know that any async code statement moves to the call-stack and then gets immediately removed and executed in a separate Web API thread (started by browser). And then the result is stored in a callback queue and those values are picked up by the event loop once the call stack is empty. </p>
  
  <p>Can anyone confirm the order in which below mentioned statements will be moved to call stack ?</p>
  
  <pre><code>Promise.resolve(function1)
    .then(function2)
    .then(function3)
    .then(function4);
  
  console.log("Hello");
  </code></pre>
  
  <p>Does the whole promise chain move to call stack or individual <code>then</code>s ?</p>