Goldman Sachs Interview Question

use pointer to traverse a list using minimum time and space complexity