title: How to convert string to Boolean in Python
body: <p>I came across this question for the interview. I had to convert the string to Boolean and return the Boolean value</p>
  <p>For ex <code>s=&quot;3&gt;1&gt;5&quot; =&gt; false</code></p>
  <p>I tried using</p>
  <pre><code>ans= bool(s)
  </code></pre>
  <p>But I always get the answer as True even though the above example gives False if we don't pass it as a string</p>