List reverse function recursive and iterative