title: Fastest way to create strictly increasing lists in Python
body: <p>I would like to find out what is the most efficient way to achieve the following in Python:</p>
  
  <p>Suppose we have two lists <code>a</code> and <code>b</code> which are of equal length and contain up to 1e7 elements.
  However, for the ease of illustration we may consider the following:</p>
  
  <pre><code>a = [2, 1, 2, 3, 4, 5, 4, 6, 5, 7, 8, 9, 8,10,11]
  b = [1, 2, 3, 4, 5, 6, 7, 8, 9,10,11,12,13,14,15]
  </code></pre>
  
  <p>The goal is to create a strictly monotonic list <code>a_new</code> from <code>a</code> whereas only the first sample point of sample points with identical values is used.
  The same indices that have to be deleted in <code>a</code> should also be deleted in <code>b</code> such that the final result will be:</p>
  
  <pre><code>a_new = [2, 3, 4, 5, 6, 7, 8, 9,10,11]
  b_new = [1, 4, 5, 6, 8,10,11,12,14,15]
  </code></pre>
  
  <p>Of course this can be done using computationally expensive <code>for</code> loops which is however not suitable due to the huge amount of data.</p>
  
  <p>Any suggestions are very appreciated.</p>