Split text - based on multiple successive Letters

Challenge,
There is a list with text items.
I would like to split (and only split) at the location where ‘CX’ are directly behind each other.
So not at only the ‘C’ or ‘X’. I tested (CX){CX}‘CX’ but didn’t work.

Probably quite easy but I can find it.2020-04-11 split text based on multiple letters.gh (6.7 KB)

Any suggestions?

thank you :slight_smile:

Try with Python

1 Like

Perfect, thanks! :slight_smile:

1 Like

Hi,
Thank you once again :).
But I just came to the concluion there is still 1 challenge to go:
Because I would like to split the items on ‘multiple’ character combinations as shown below.
Unfortunately it is only testing the first character combination to the first item , and the second combi to the second item, instead of testing all the items against the 3 possible chracter comninations.

The same is happening for the HS_Kim solution :slight_smile:

2020-04-11 split text based on multiple letters_re_RE.gh (9 KB)

Any suggestions?

Thanks again!

This is different

txt.gh (5.2 KB)

1 Like