title: How can I use f-string with a variable, not with a string literal?
body: <p>I want to use f-string with my string variable, not with string defined with a string literal, <code>&quot;...&quot;</code>.</p>
  <p>Here is my code:</p>
  <pre><code>name=[&quot;deep&quot;,&quot;mahesh&quot;,&quot;nirbhay&quot;]
  user_input = r&quot;certi_{element}&quot; # this string I ask from user  
  
  for element in name:
      print(f&quot;{user_input}&quot;)
  </code></pre>
  <p>This code gives output:</p>
  <pre><code>certi_{element}
  certi_{element}
  certi_{element}
  </code></pre>
  <p>But I want:</p>
  <pre><code>certi_{deep}
  certi_{mahesh}
  certi_{nirbhay}
  </code></pre>
  <p>How can I do this?</p>