Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

It works for me, except I had to change normalizeVectorList to normalizeVectorL which is the name of the function you defined in your example. Please make sure you are running the actual code you think you're running by creating and verifying a Minimal, Complete, Reproducible Example.

As an aside I'm a little confused by this construction and the one below it:

VVVlist=[]
VVVlist0=[]
VVVlist0.append([1,1,1])
VVVlist0.append([1,1,2])
VVVlist0.append([1,0,0])
VVVlist.append(VVVlist0)

This is just equivalent to writing:

VVVlist = [[[1, 1, 1], [1, 1, 2], [1, 0, 0]]]

and so on. You can nest list literals as much as you need to and I think it makes for much clearer code.