I have two arrays in my code. One is a grid that is just filled with zero and the other is an array of characters with positions they need to be placed in on the grid. I included an image with my position array on the top and the grid on the bottom.
I’m trying to fill in the grid given the characters positions. For example, I would write this
grid[0][0] = pos[0][0]
To place the character * on the top left. However it’s giving me a value error
ValueError: could not convert string to float: '*'
I assume this is because the grid element is a float integer the position elements is a string. Is there any way around this?