title: Wondering the time complexity of an algorithm
body: <p>In my job I had to implement an algorithm, the specifics details does not matters, but I was unable to have a clear answer about the time complexity of this specific algorithm.</p>
  <p>In a nutshell it's look like something like that:</p>
  <pre><code>for(let i = 0; i &lt; 3; i++) {
      for(let j = 0; j &lt; n - 1; j++) {
          for(let k = 0; k &lt; 8; k++ {
              // Do some stuff
          }
      }
  }
  </code></pre>
  <p>What is the time complexity of this algorithm ?</p>
  <p>At the beginning I thought it would be something like O(n^3). But the more I think about, the more I think it's actually more a 0(n). Because, even though we have 3 for loop, only one can be of a variable size, the two other are constant.</p>
  <p>So what is the actual time complexity of this algorithm ? Is it O(n^3), O(n) or even something else ?</p>