Listnode Length Python Function Example Code Java