Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

For loop strange order of execution

On server I have run this code:

for k in [0..(len(G)-1)]:
    graphics_array([G[k][2].plot(color_by_label={'p':'black', 'r':'blue'}),G[k][3].plot(color_by_label={'p':'black', 'r':'blue'}),G[k][4].plot(color_by_label={'p':'black', 'r':'blue'})])

and I obtain correct effect, that is two elements ( which is text) G[k][0],G[k][1] and then plot for 3 additional elements in graphics array 1x3.

On my own instance of sagemath ( ver. 6.8) there is complete different! The same code produces first list of 36 elements of G[k][0],G[k][1] and thet 36 plots.

Is this normal?