title: Manipulating Python Lists
body: <p>I have a list of 100 elements. I am trying to create a function that will make 300 copies of that list and then store those copies into a blank list. I then need the function to choose an indexed value at random from each copied list. So, it might choose the 25th index value in the first copied list, and then it might choose the 60th index value in the next copied list. Then, the index of the value is an argument of a pre-defined function. The problem is that my copied lists are not being manipulated. </p>
  
  <p>my code is as follows:</p>
  
  <pre><code>def condition_manipulate(value):
      list_set=[]                  #this is the list in which the copied lists will go
      for i in range(0,value):
          new_list=initial_conditions[:]    #initial_conditions is the list to be copied
          list_set.append(new_list)
          for i in list_set:           #My confusion is here. I need the function to choose
              for j in i:              #A random value in each copied list that resides
                   x=random.choice(i)  #In list_set and then run a predefined function on it.
                   variable=new_sum(i.index(x)
                   i[i.index(x)]=variable
      return list_set
  
  #running condition_manipulate(300) should give me a list with 300 copies of a list
  #Where a random value in each list is manipulated by the function new_sum
  </code></pre>
  
  <p>I have tried almost everything. What am I doing wrong? Any Help will be appreciated. Thanks.</p>