Another implementation using 'last' from Data.List

Also fix the Type in the comment.