<qiyuangong>003_Longest_Substring_Without_Repeating_Characters_3.py
def lengthOfLongestSubstring( s):
    charMap = {}
    for i in range(256):
        charMap[i] = -1
    ls = len(s)
    i = max_len = 0
    for j in range(ls):
        if charMap[ord(s[j])] >= i:
            i = charMap[ord(s[j])] + 1
        charMap[ord(s[j])] = j
        max_len = max(max_len, j - i + 1)
    return max_len
def sample_funcname ( var_0 ) :
    var_1 = { }
    for var_4 in range ( 256 ) :
        var_1 [ var_4 ] = - 1
    var_7 = len ( var_0 )
    var_4 = var_8 = 0
    for var_10 in range ( var_7 ) :
        if var_1 [ ord ( var_0 [ var_10 ] ) ] >= var_4 :
            var_4 = var_1 [ ord ( var_0 [ var_10 ] ) ] + 1
        var_1 [ ord ( var_0 [ var_10 ] ) ] = var_10
        var_8 = max ( var_8 , var_10 - var_4 + 1 )
    return var_8
