Diebold Nixdorf Interview Question

remove duplicated elements from LL