Custom list distribution every specific time

Hello…

I have a field that use a custom list with two item _b and _g
For every 40 entry, I need the _b to be randomly 35 times and the _g 5 times. then repeated for the next 40…

I’m lost at which distribution method I should use and which rules can allow this if I use a custom distribution.

Any help will be appreciated.