List.remove() gives error message when element is not found.