title: Understanding multilevel feedback queue scheduling
body: <p>I'm trying to understand multilevel feedback queue scheduling and I came across the following example from William Stallings Operating Systems Internal and Principles Design (7th ed). </p>
  
  <p>I got this process:</p>
  
  <p><img src="https://i.stack.imgur.com/VGZ51.png" alt="enter image description here"></p>
  
  <p>And the result in the book is this:
  <img src="https://i.stack.imgur.com/W8jsg.png" alt="enter image description here"></p>
  
  <p>I believe I'm doing the first steps wright but when I get to process <code>E</code> CPU time my next process is <code>B</code> not <code>D</code> as in the book example.</p>
  
  <p>I can't understand if there are <code>n</code> <code>RQ</code> and after each time a process get's CPU time it is demoted to a lower priority time <code>RQ</code> or if, for example, process <code>A</code> is in <code>RQ1</code> and there are no process at the çower <code>RQ</code>, the process is promoted to that ready queue (this is how I am doing).</p>
  
  <p>Can someone explain me the process how, at the above example, after <code>E</code> is processed, <code>D</code> gets CPU time and them <code>E</code> (and not <code>B</code>) is served?</p>