Filling multiple columns

Dear all,

I have a table with following columns:

key

count

a H001

b H001

a H002

b H002

…

a H010

b H010

Depending on the value from column count I have to copy the value from a H001 and aH002 to the other columns; e.g. when

count = 2: I have to fill the fields a H002, b H002 with a H001, b H001

count = 3: I have to fill the fields a H002, b H002, a H003, b H003 with a H001, b H001

count = 4: I have to fill the fields a H002, b H002, a H003, b H003, a H004, b H004 with a H001, b H001

…

In VBA I would realize this with a for next construct; in knime I found the only way doing it with java snippet.

Is there a smarter way (in real i have a H001, b H001, c H001, d H001, e H001, f H001, g H001, h H001 to a H020, b H020, c H020, d H020, e H020, f H020, g H020, h H020

Attached you can find input and wanted input result.

Thanks for help!

BR,

Heinz

test 6 to Knime from HS.knwf