Why is a list access O(1) in Python?
<p>I understand that a list is different from an array. But still, O(1)? That would mean accessing an element in a list would be as fast as accessing an element in a dict, which we all know is not true.
My question is based on <a href="https://wiki.python.org/moin/TimeComplexity" rel="noreferrer">this document</a>:</p>

<blockquote>
<pre><code>list

----------------------------
| Operation | Average Case |
|-----------|--------------|
|    ...    |     ...      |
|-----------|--------------|
|  Get Item |     O(1)     |
----------------------------
</code></pre>
</blockquote>

<p>and <a href="https://stackoverflow.com/questions/513882/python-list-vs-dict-for-look-up-table">this answer</a>:</p>

<blockquote>
  <p>Lookups in lists are O(n), lookups in dictionaries are amortized O(1),
  with regard to the number of items in the data structure.</p>
</blockquote>

<p>If the first document is true, then why is accessing a dict faster than accessing a list if they have the same complexity?</p>

<p>Can anybody give a clear explanation on this please? I would say it always depends on the size of the list/dict, but I need more insight on this.</p>