title: how can I execute a string formatting with out using exec function in python
body: <p>I have an exec statement to set the formatting of two variables in python 3.6. Even though the code works fine, I need to change this due to compliance issue. Please let me know how it can be done differently.</p>
  <p>My statement: exec(&quot;{}='{}'&quot;.format(item,s))</p>
  <p>thanks in advance for your help.</p>