Skip to content
Advertisement

Tag: memoization

Frog Jump Memoization(Python)

Below is the problem description, followed by its recursive solution using Python. This solution is inefficient. I know using memoization, we can improve this solution. I have also gone through …

Does Python intern strings?

In Java, explicitly declared Strings are interned by the JVM, so that subsequent declarations of the same String results in two pointers to the same String instance, rather than two separate (but identical) Strings. For example: My question is, does CPython (or any other Python runtime) do the same thing for strings? For example, if […]

Advertisement