I have a list of lists. I want to find the euclidean distance between all the pairs and itself and create a 2D numpy array. The distance between itself will have 0 in the place and the value when the pairs are different.
Example of List of Lists:[[0, 42908],[1, 3],[1, 69],[1, 11],[0, 1379963888],[0, 1309937401],[0, 1],[0, 3],[0, 3],[0, 77]]
The result I want is
0 1 2 3 4 5 6 7 8
0 0 x x x x x x x x
1 0 x x x x x x x
2 0 x x x x x x
3 0 x x x x x
4 .................
5 .................
6 .................
7 .................
8 .................
x represents the values of differences. The periods mean the result shall follow as it shows in the matrix. I need help with the code in python. The number of 0,1,2 etc in rows and columns define the inner list index.