<s> """<STR_LIT>""" <EOL> __author__ = '<STR_LIT>' <EOL> class Solution ( object ) : <EOL> def maxSubArrayLen ( self , A , k ) : <EOL> """<STR_LIT>""" <EOL> m = { <NUM_LIT:0> : - <NUM_LIT:1> } <EOL> maxa = <NUM_LIT:0> <EOL> s = <NUM_LIT:0> <EOL> for i in xrange ( len ( A ) ) : <EOL> s += A [ i ] <EOL> t = s - k <EOL> if t in m : <EOL> maxa = max ( maxa , i - m [ t ] ) <EOL> if s not in m : <EOL> m [ s ] = i <EOL> return maxa </s>
