Super Clean Code Python
The idea is that you keep a "ghost" point which keeps moving and whenever the ghost point takes a step you check if it\'s valid. If valid, append to the return 
The idea is that you keep a "ghost" point which keeps moving and whenever the ghost point takes a step you check if it\'s valid. If valid, append to the return array. \n\n```\nclass Solution(object):\n    \n    def spiralMatrixIII(self, R, C, r0, c0):\n        ret = [(r0, c0)] \n        is_valid = lambda row, col: row >= 0 and row < R and col >= 0 and col < C \n        \n        steps = 1 \n        r, c = r0, c0 \n        while len(ret) < R * C: \n            # Go east 1\n            for step in xrange(steps):\n                r, c = r, c + 1 \n                if is_valid(r, c): ret.append((r, c))\n                    \n            # Go down 1 \n            for step in xrange(steps):\n                r, c = r + 1, c \n                if is_valid(r, c): ret.append((r, c))\n                    \n            steps += 1\n                    \n            # Go west 2 \n            for step in xrange(steps):\n                r, c = r, c - 1\n                if is_valid(r, c): ret.append((r, c))           \n            \n            # Go north 2 \n            for step in xrange(steps):\n                r, c = r - 1, c \n                if is_valid(r, c): ret.append((r, c))           \n                    \n            steps += 1\n            \n        return ret \n```
[]