Convert list, for later reference.
Use map for smarter iteration.
Input part completed.