I have two lists A: contains number from 1 to 10, and B contains percentage values. I'd like to print them in this way
1: 10%, 2: 40%, 3: 50%
I managed to write only one array but I can't find a way to write both of them.
print(' : '.join(str(x) for x in A))
I tested zip but it printed only the first value of A and the rest of B
print(''.join(str(x) + " : " + str(y) for x, y in zip(A, B)))
0 : 2821 : 3422 : 2963 : 3024 : 3155 : 2496 : 3067 : 3198 : 2729 : 317
Any idea how to implement it without using for loop ?