title: How to change certain numpy array's target value to another value (if a list of target values is available)?
body: <p>I have a following array:
  <code>arr = np.arange(24).reshape(4, 6)</code></p>
  <p>and have a list of target values that should be changed:
  <code>target = [0, 2, 8]</code></p>
  <p>Now I would like to change all target values in arr to 100.
  I could perform that with:</p>
  <p><code>arr[(arr == 0)|(arr == 2)|(arr == 8)] = 100</code></p>
  <p>It is not practicable if I have long lists (with 10 elements).
  Is there a better way to perform it without using for loop?
  Thank you for any inputs :-)</p>