[Java] Small code with Recursion with Memoization
```\n int[][]dp;\n    public int minInsertions(String s) {\n        int n = s.length();\n        dp = new int[n][n];\n        for(int i=0; i=j) return 0;\n     
```\n int[][]dp;\n    public int minInsertions(String s) {\n        int n = s.length();\n        dp = new int[n][n];\n        for(int i=0; i<n; i++) {\n            Arrays.fill(dp[i], Integer.MAX_VALUE);\n        }\n        int res = find(s.toCharArray(), 0, s.length()-1);\n        return res;\n    }\n    \n    int find(char[] str, int i, int j) {\n        if(i>=j) return 0;\n        if(dp[i][j] != Integer.MAX_VALUE) return dp[i][j];\n        \n        if(str[i] == str[j]) {\n            dp[i][j] = find(str, i+1, j-1);\n        } else {\n            dp[i][j] = Math.min(find(str,i+1,j)+1, find(str,i,j-1)+1);\n        }\n        \n        return dp[i][j];\n    }
[]