mercredi 30 juin 2021

In Netlogo, how to randomly choose an element from a list, and let this element plus one, and then create a new list?

For example, now I have a list: [0 0 0]

I want to randomly choose an element from this list, for example, randomly I choose the first element.

Then I plus it by 1.

So now the new list is [1 0 0].

My question is how to create this new list [1 0 0] in Netlogo?




Aucun commentaire:

Enregistrer un commentaire