LCS returning array