title: How to Override Values In-Place for List using MultiProcessing in Python 3?
body: <p>I've been trying to Run the following Code:</p>
  <pre><code>from math import inf
  import multiprocessing
  
  dist = [[inf] * n for _ in range(n)]
  
  n = 8
  data = [i for i in range(n)]
  
  def set_self_distance(data):
      for i in range(data[0],data[-1]):
          dist[i][i] = 0
  
  processes = multiprocessing.cpu_count()
  pool = multiprocessing.Pool(processes=processes)
  size = int(math.ceil(float(len(data)) / processes))
  data = [data[i * size:(i + 1) * size] for i in range(processes)]
  pool.map(set_self_distance, data)
  </code></pre>
  <p>I've tried various versions and have the following issues:</p>
  <ul>
  <li>Either getting 'n' copies of dist[ ][ ] inside dist  ||OR||</li>
  <li>There is no change at all in dist[ ][ ].</li>
  </ul>
  <p>EDIT : Added Missing Code Definition for dist[ ][ ].
  <br>I want to Update Values using MultiProcessing In-Place in the List 'dist [ ][ ]'.
  <br>Thank You :)</p>