Python data structure similar to dictionary where key is two values?
<p>I am looking for a data structure in Python that is similar to a dictionary. The difference is that there is two keys. I want to be able to access the value in constant time.
Like:</p>

<pre><code>dict.get(dog, smurf)
{(dog, smurf): 40}
</code></pre>

<p>Is this possible?</p>

<p>If this doesn't exist, I would just do a dictionary in a dictionary. But, the above would be more convenient.</p>

<pre><code>{dog: {(smurf: 40)}}
</code></pre>
