Directory descent code working