scala> nums.head res0: Int = 1 scala> names.head res1: String = joel
It’s used to print the first element (the head element) of a list.
Clickable & Draggable!