Hi folks, I made a mistake during the implementation; in the if-block that says "if letter not in seen:" we need to add a line `memo[(source, letter)] = cost` in order for this code to run as fast as it can (without changing the fundamental algorithm of course). The correct code is linked on my post on LeetCode: leetcode.com/problems/minimum-cost-to-convert-string-i/solutions/4449543/beats-100-easy-for-everyone-optimized-for-readability-video-walkthrough/
Hi folks, I made a mistake during the implementation; in the if-block that says "if letter not in seen:" we need to add a line `memo[(source, letter)] = cost` in order for this code to run as fast as it can (without changing the fundamental algorithm of course). The correct code is linked on my post on LeetCode: leetcode.com/problems/minimum-cost-to-convert-string-i/solutions/4449543/beats-100-easy-for-everyone-optimized-for-readability-video-walkthrough/
Good video brother, the contest was finished just yesterday yet you already made this awesome explanation video. Thanks!
Loved your video keep going ❤