Improve console output performance using Array#concat instead of #<< with #flatten