I have i
and need o
.
i = ["file1", "file2", "join", "file3", "file4", "join", "file5", "file6"]
o = [["file1", "file2", "join"], ["file3", "file4", "join"], "file5", "file6"]
I tried so many hours and attempts that I can't reasonably show what I tried so far. while
, pop
, index
etc come to my mind. Please bear with me, if I now only put these plain lines in order to ask for your precious help.