Using List.first instead of Enum.at(0)

There is a difference between hd and List.first
List.first show nil in empty but hd raise error in that case.