Runtime:  40 ms , faster than  21.32% of Python3 online submissions for Set  Unique Paths .

Memory Usage:  14.4 MB , less than  15.17%   of Python3 online submissions for Set  Unique Paths .

If you have any questions regarding my code, feel free to ask in the comments :)