Problem · String
Interleave Equal-Length Strings by Column
Learn this problemProblem statement
Given three equal-length strings, build a new string by taking the character at index 0 from all three strings, then the character at index 1 from all three strings, and so on.
Function
interleaveStrings(first: String, second: String, third: String) → StringExamples
Example 1
first = "abc"second = "def"third = "ghi"return = "adgbehcfi"Reading each column produces adg, then beh, then cfi.