Looking for a Simple Python script to create Table (solved without python)

I’m looking for a simple python script to create a table.
The goal is to repeat a list a given number of times.
if I were to have these inputs.
a b c
I want the output
a b c
a b c
a b c

Thanks in advance.

If you’re interested about the why:

I’m using the Element.SetParameterByName node and I’m trying to make it more elegant and versatile, currently, the parameterName input is a list, the value input a table, but to make it work the node “wants” to have a table for the element before it works.

Solved with the help of @MJB-online:

See if you can find what you need in this thread

Hi @PauLtus,

The “List.Cycle” node can create a list, by repeating a given value.

If you combine that with the “List.Count” node (on your other list), it gives you the right amount of values.

Kind regards,

1 Like

Thanks a lot!
I wish I knew that existed a bit earlier, I’ve actually gone through the entire list of nodes with the word list in it but hadn’t found it.

After some minor alterations I managed to get what I wanted.

I did want the input list to be an actual list and not simply a string but after some splitting up I managed to get what I wanted: