comefrom: <garvit244>1027_1.py
code: def longestArithSeqLength( A):
      from collections import defaultdict
      
      dp = defaultdict(int)
      for index_i in range(len(A)):
          for index_j in range(index_i):
              diff = A[index_i] - A[index_j]
              dp[(index_i, diff)] = max(dp[(index_i, diff)], dp[(index_j, diff)]+1)
      return max(dp.itervalues())+1
masked: def sample_funcname ( var_0 ) :
      from var_1 import var_2
      var_3 = var_2 ( int )
      for var_4 in range ( len ( var_0 ) ) :
          for var_5 in range ( var_4 ) :
              var_6 = var_0 [ var_4 ] - var_0 [ var_5 ]
              var_3 [ ( var_4 , var_6 ) ] = max ( var_3 [ ( var_4 , var_6 ) ] , var_3 [ ( var_5 , var_6 ) ] + 1 )
      return max ( var_3.itervalues ( ) ) + 1
  