realise list by array and pointer