comefrom: <awangdev>Coins in a Line III_3.java
code: private void search(int i, int j, int[][] dp, int[][] sum, int[] values) {
  
          if (dp[i][j] > 0)  {
              return;
          }
          if (i == j) {
              dp[i][j] = values[i];
          } else if (i > j) {
              dp[i][j] = 0;
          } else if (i + 1 == j) {
              dp[i][j] = Math.max(values[i], values[j]);
          } else {
              search(i + 1, j, dp, sum, values);
              search(i, j - 1, dp, sum, values);
              dp[i][j] = sum[i][j] - Math.min(dp[i + 1][j], dp[i][j - 1]);
          }
      }
masked: private void sample_funcname ( int i , int j , int [ ] [ ] dp , int [ ] [ ] sum , int [ ] values ) {
    if ( dp [ i ] [ j ] > 0 ) {
      return ;
    }
    if ( i == j ) {
      dp [ i ] [ j ] = values [ i ] ;
    }
    else if ( i > j ) {
      dp [ i ] [ j ] = 0 ;
    }
    else if ( i + 1 == j ) {
      dp [ i ] [ j ] = Math . max ( values [ i ] , values [ j ] ) ;
    }
    else {
      search ( i + 1 , j , dp , sum , values ) ;
      search ( i , j - 1 , dp , sum , values ) ;
      dp [ i ] [ j ] = sum [ i ] [ j ] - Math . min ( dp [ i + 1 ] [ j ] , dp [ i ] [ j - 1 ] ) ;
    }
  }
  