title: How to make the loop pause until user input in telegram python bot?
body: <pre><code>        for job in jobs:
          def gen_markup():
              markup = InlineKeyboardMarkup()
              markup.row_width = 1
              markup.add(InlineKeyboardButton(text='לאתר מתגייסים', url=job[3]))
              return markup
          if int(job[6]) &lt;= int(user.dpr):
              if str(user.sex) == 'זכר':
                  if int(user.profil) &gt;= int(job[7]) and int(user.profil) &lt;= int(job[8]):
                      msg = bot.send_message(message.chat.id, &quot;&lt;b&gt;&quot; + str(job[1]) + &quot;&lt;/b&gt;&quot; + &quot;\n&quot; + str(job[2]), reply_markup = gen_markup(), parse_mode='HTML')
                      // here i want to ask user if he wants to continue the jobs loop
              else:
                  if int(user.profil) &gt;= int(job[9]) and int(user.profil) &lt;= int(job[10]):
                      msg = bot.send_message(message.chat.id, &quot;&lt;b&gt;&quot; + str(job[1]) + &quot;&lt;/b&gt;&quot; + &quot;\n&quot; + str(job[2]), reply_markup = gen_markup(), parse_mode='HTML')
                      // here i want to ask user if he wants to continue the jobs loop
  </code></pre>
  <p>Hello, I have difficulty implementing thing which will pause the loop until the user input (until he will want to continue the loop). What do I need to write in code for doing that?</p>