algorithmic modeling for Rhino
Hi!
Basic list question, but I can not find answer anywhere..
I have 100 circles, circles are divided into 3 to 7 parts by random.
How can I divide that resulting list (3to7 points per circle) into 5 chunks ->
1 chunk with all items that divide circle into 3 parts.
2 chunk with all items that divide circle into 4 parts.
3 chunk with all items that divide circle into 5 parts.
etc. until items that divide circle into 7 parts.
Hope you can understand my problem.
I added image of definition below.
Thanks!
Tags:
You must give the same amount of values in both parameters. Therefore, you have to repeat 6 times 6, 5 times 5, 4 times 4, 7 times 7, and 3 times 3..., altogether a list of 6 + 5 + 4 + 7 + 3... elements, a value for each point.
This script is wrinting in C#, not C++. And of course, can be done with standard components, perhaps someone else help you with that.
Ok, I understand that part about same amount of values.
But how can I achieve that if random component divides circles every time in different length list ?
Ok I did found answer!
Had to use longest list component..
Thanks for help!
Have a great weekend!
See you've already found your answer - but here's what I came up without C# scripting.
Brilliant!! I always struggle with lists..
Thanks!
thanks!!
Welcome to
Grasshopper
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
© 2024 Created by Scott Davidson. Powered by