0

How do you create x amount of arrays each with different names. For example if I wanted to create 10 arrays using a for loop and they each need to have a common name. Each array's name has to be Cluster1, Cluster2 and so on.

I have tried putting an array into an array but am unable to create names for each of the new arrays and am also having trouble accessing each value of the array in an array.

Adi
  • 1
  • 1
    Could you give an example of the kind of data structure you're trying to achieve? It seems like what you may be after is a dictionary of lists though. my_dict = {"cluster1": [1,2,3,4], "cluster2": [5,6,7,8], ... } – JohnO May 26 '19 at 17:03
  • Possible duplicate of [Creating variable number of variables in python](https://stackoverflow.com/questions/45015360/creating-variable-number-of-variables-in-python) – Devesh Kumar Singh May 26 '19 at 17:06

0 Answers0