How would I go about doing a while statement in Dynamo?

So I have a list of xyz coordinates (named l) as shown below:


So I want to run this while statement (C++ format) in dynamo but I can’t figure out how.

Firstly, I don’t understand the whole [Imperative] thing, and even if I do, the action of placing a receptacle feels like it needs to be done using a node rather than in a code block.

Secondly, I can’t figure out how to do a while statement in Dynamo. The description it gives isn’t enough and I can’t find any help online.

Any suggestions?


Did you look over the design script language manual (check section 12 closely):