title: Python-equivalent of short-form "if" in C++
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/394809/python-ternary-operator">Python Ternary Operator</a>  </p>
  </blockquote>
  
  
  
  <p>Is there a way to write this C/C++ code in Python?
  <code>a = (b == true ? "123" : "456" )</code></p>