1# Basix syntax:
2['delim'.join([str(elem) for elem in sublist]) for sublist in my_list]
3# Where delim is the delimiter that will separate the elements of the
4# nested lists when they are flattened to a list of strings
5
6# Note, this uses two "levels" of list comprehension
7
8# Example usage 1:
9my_list = [[1, '1', 1], [2,'2',2], [3,'3',3]]
10[' '.join([str(elem) for elem in sublist]) for sublist in my_list]
11--> ['1 1 1', '2 2 2', '3 3 3'] # List of space-delimited strings
12
13# Example usage 2:
14my_list = [[1, '1', 1], [2,'2',2], [3,'3',3]]
15['_'.join([str(elem) for elem in sublist]) for sublist in my_list]
16--> ['1_1_1', '2_2_2', '3_3_3'] # List of underscore-delimited strings