title: Is there a way to code this with an if else statement and get a similar result?
body: <ol>
  <li>Is there a way to code this with an if else statement and get a similar result (MENU display part) ?</li>
  </ol>
  <p>print (&quot;A. Snack 1 - - - - - - - - - - - - - $1.80: {}&quot;.format( &quot;Available&quot; if amount &gt;= item_a and stock_a &gt; 0 else &quot;Insufficient coins&quot; if stock_a &gt; 0 else &quot;Sold out&quot;))</p>
  <p>Need to check if coin insert is sufficient if not display insufficient coins and also check if there are stock.</p>
  <ol start="2">
  <li><p>print(&quot;Current amount: ${}&quot;.format(&quot;%.2f&quot; % (amount / 100)))
  Is there other way to print the current amount without using the {} ?</p>
  </li>
  <li><p>print(&quot;Selection {} not on menu.&quot;.format(insert.upper()))
  Is there other way to print this without using the {} ?</p>
  </li>
  <li><p>What do I enter to try out if the chance of being stuck is working?</p>
  </li>
  </ol>
  <p>Thanks in advance!</p>