Here is my string
a = '(20.0, 8.0, 8.0, 37.0)'
and i want only first three items in this format
str = 20.0x8.0x8.0
and store the last item in a list.
leftover = [37.0]
Earlier I had only three dimensions in the string so I was using replace function multiple times to convert it.
converted = str(''.join(str(v) for v in a)).replace("(","").replace(")","").replace(", ","x")
I know it's not the most pythonic way but it was doing the trick. But I have no clue how to remove an element from str(tuple)