<doocs>2315.Count Asterisks_1.py
def countAsterisks( s: str) -> int:
    ans = t = 0
    for c in s:
        if c == '|':
            t ^= 1
        elif c == '*':
            if t == 0:
                ans += 1
    return ans
def sample_funcname ( var_0 : str ) -> int :
    var_5 = var_3 = 0
    for var_6 in var_0 :
        if var_6 == '|' :
            var_3 ^= 1
        elif var_6 == '*' :
            if var_3 == 0 :
                var_5 += 1
    return var_5
