I have a list of integer
a=[1,2,3,4,5,6,7,8,9]
and i must create a string with the integers separated by spaces and every five number i must add a '\n'
string='1 2 3 4 5\n6 7 8 9\n\n'
I have tried with a join like that:
string=' '.join(a)
but i don't know how to add '\n' with a condition.