I have a huge list with hundreds of thousands of numbers. The list is badly formatted when produced by sagemath, but i must have it in the kind of formatting shown below to "feed" it to another function. Here is sample of the well formatted list:
C=[
( 7.850629, 25.421135, 22.162571),
( 37.706629, 28.421472, 0.229876),
( 37.560629, 21.421809, 18.320977),
( 39.238629, 26.422147, 18.442572),
( 35.087169, 0.419785, 15.055789),
]
As you can see, all elements are aligned to the right as well as based on the precision and decimal place. So my question is this: How can i convert the badly formatted list (example shown below) to the well formatted above
B=[(37.074945, 22.414327,
9.756234), (37.074945, 22.414665,
1.669214), (37.074945, 22.415002,
8.571376), (37.074945, 22.41534,
1.294731), (37.074945, 22.415677,
5.753062), (37.074945, 22.416014,
7.519850)]
(If i could describe it even a bit more, i would say that if my list is thought of as a matrix, then it would have tenths of thousands of rows and three columns)