How to replace " (double quote) with space or remove space?
<p>It's a very simple and basic question that remove double quotes in python, I couldn't get it.</p>

<pre><code>print text
"'abc' : 'xyz'"
</code></pre>

<p>I want it to display as below</p>

<pre><code>'abc' : 'xyz'
</code></pre>

<p>tried many ways but didn't get the required way</p>

<pre><code>text.replace("\""," "); # but it display as it is.
</code></pre>

<p>Could someone tell me to correct syntax?</p>

<p>The <code>replace</code> method does not modify the string in place, but it returns the new value. So you can try</p>

<pre><code>text = text.replace('"', '')
</code></pre>

python python-2.7