I have an array in python:
ARR1 = ['A', 'B', 'C', 'D']
and another array, which uses previous array random value for one of the elements
ARR2 = ['1', '2', '3', random.choice(ARR1)]
when I invoke print(ARR2[]) I get random value on last position and this is fine.
Now I have a for in loop:
for i in range(3):
print(ARR2[])
and I get the same random value every 3 times, like:
['1', '2', '3', 'B'] ['1', '2', '3', 'B'] ['1', '2', '3', 'B']
What I would like is, 5 random values, like:
['1', '2', '3', 'D'] ['1', '2', '3', 'A'] ['1', '2', '3', 'C']
How I understand it, the array ARR2, would have to be initialized, every time it is called in for loop.
Is it doable in Python?