title: How can I minimize code here so that its more memory efficient in python3?
body: <p>I was going through problems on www.spoj.com and the prime generator problem caught my attention as a good warmup problem to get started.
  The problem is straight forward and easy to code. But, every time I submit my code I get a run time error. I'm guessing it's a code efficiency problem and I would love to expand my knowledge on what is memory efficient and what is not.<br>
  <a href="https://www.spoj.com/problems/PRIME1/" rel="nofollow noreferrer">https://www.spoj.com/problems/PRIME1/</a></p>
  
  <pre><code>import numpy as np
  run_times = int(input())
  for i in range(run_times):
      search_range = list(map(int, input().split()))
      for j in range(search_range[0], search_range[1]):
          a = j%np.arange(2, j)
          if 0 in a:
              pass
          elif 0 not in a and j&gt;0 :
              print(j)
  </code></pre>