Performance Improvement

Seq.zip will enumerate the headers for each row, which will repeat the regex matching. Freeze the computation by using Array.map instead of Seq.map