Given a 2d matrix of strings, I would like to concatenate the elements in the sublists based on their position.
e.g. Given this data structure as input:
[['x','y' ,'z'],['A', 'B', 'C'], ['a', 'b', 'c']]
The algorithm would produce the output:
['xAa', 'yBb', 'zCc']
I tried R.transpose, but it gets me [['x','A','a'], ['y', 'B', 'b'], ['z', 'C', 'c']], however I couldn't find a way to concatenate the nested strings.
I also tried R.zipWith, but it doesn't look ideal since R.zipWith takes only two arguments so that I need to apply it twice to get the output.