Extrude with Random Factor from Predefined Values

Hey everyone,

I have sets of curves that I want them to be extruded randomly from a list of predefined values. I am not sure if I am using correct terminology so I gave an example of what I am trying to achieve:

I have 10 curves and 6 predefined values (5, 10, 15, 20, 25, 30). I want curves to be extruded with these values. Each value can be used more than once but cannot be excluded.

Thanks in advance.

3. Attach minimal versions of all the relevant files

Random Value Extrusion.gh (6.8 KB)
Random Value Extrusion.3dm (2.9 MB)

You have only 5 curves and six values so one of the curves is extruded twice.

P.S. With ten curves, it might look like this:


Random Value Extrusion_2024_Jun23a.gh (9.6 KB)

Or maybe like this?


Random Value Extrusion_2024_Jun23b.gh (9.6 KB)

Or like this?


Random Value Extrusion_2024_Jun23c.gh (10.7 KB)

Hey thanks!
I applied yours to one part of the original file. Jun23a and Jun23b work like a charm. First one was OK too but it used one of the values too many times.

I am trying to achieve stalactite-like structure. Here’s the small part of the original file that I am working on with your options.
Random Value Extrusion.gh (13.7 KB)
Random Value Extrusion.3dm (2.9 MB)