Creating a true/false list from predefined list lenght and input value

Dear Grasshopper community,

I need a little help to create a True/False List.

I would need to create for example a list with 10 indexes. Based on an external value, e.g. 4, I need that the list have the first 4 indices with a true value and the other 6 indices with a false value.

Could you point me in the right direction?

Thanks in advance

Hi,

Something like this?

Instead of the sliders, you could drive the duplication with other data (e.g. list length, etc.).

true_false.gh (7.2 KB)