On Wed, Jul 28, 2010 at 4:02 AM, Dave Castellano
<dcastellano1 / wideopenwest.com> wrote:
> Hi,
>
> Can anyone help me with the correct syntax to insert into a
> multidimensional array...
>
> answer_choices =3D [
> =A0[incorrect_ans_2, incorrect_anno_2],
> =A0[incorrect_ans_3, incorrect_anno_3],
> =A0[incorrect_ans_4, incorrect_anno_4],
> =A0[incorrect_ans_5, incorrect_anno_5]
> =A0 ]
>
>
> # Randomly insert correct answer.
> =A0x =3D rand(4)
> =A0answer_choices.insert???????? =A0correct_ans_1
> =A0answer_choices.insert???????? =A0correct_anno_1
>
>
> I want to insert correct_ans_1 into position [x,0] and correct_anno_1
> into position [x,0].

You nearly had it in that sentence:

answer_choices[x][0] =3D correct_ans_1
answer_choices[x][1] =3D correct_ano_1

(I assume you wanted to insert the correct_anno_1 in position 1 of the arra=
y).

Jesus.