Python 2.7: Print a dictionary without brackets and quotation marks
<pre><code>myDict = {"Harambe" : "Gorilla", "Restaurant" : "Place", "Codeacademy" : "Place to learn"}
</code></pre>

<p>So, I want to print out a dictionary. But I want to do it like it looks like an actual list of things. I can't just do <code>print myDict</code>, as it will leave all the ugly stuff in. I want the output to look like <code>Harambe : Gorilla, Restaurant : Place, etc</code></p>

<p>So what do I do? I haven't found a post meeting what I want. Thanks in advance.</p>

<p>My solution:</p>

<pre><code>print ', '.join('%s : %s' % (k,myDict[k]) for k in myDict.keys())
</code></pre>

python python-2.7 dictionary printing