not getting random node as head