I have a list in Python.
I have tried to set print(*arr, sep=",") refer "Print list without brackets in a single row". But my real problem is:
### List
num = 2
arr= [0, "txt", 4, 5, [3,4, num]]
# print full
print(arr)
# print an arr without brackets
print(*arr, sep=",")
Expected result: 0,txt,4,5,3, 4, 2
Actual result: 0,txt,4,5,[3, 4, 2]
The compiler does not remove brackets from sub-list. Please give me advice to fix it. Thanks!