title: Appending a list through if condition in python
body: <p>This could be a very basic question, but I realized I am not understanding something.</p>
  
  <p>When appending new things in for loop, how can I raise conditions and still append the item?</p>
  
  <p>For instance:</p>
  
  <pre><code>alist = [0,1,2,3,4,5]
  new = []
  for n in alist:
      if n == 5:
          continue
      else:
          new.append(n+1)
  
  print(new) 
  </code></pre>
  
  <p>Gets me</p>
  
  <pre><code>[1, 2, 3, 4, 5]
  </code></pre>
  
  <p>How do I get </p>
  
  <pre><code>[1, 2, 3, 4, 5, 5] # 4 is incremented, 5 is added 'as is'
  </code></pre>
  
  <p>Essentially, I want to tell python to not go through <code>n+1</code> when <code>n==5</code>.</p>
  
  <p>Would this be the only solution? append n==5 separately in a list and then sum new and the separate list?</p>