def count_char_position(str1):
     
    count_chars = 0
    for i in range(len(str1)):
        if ((i == ord(str1[i]) - ord('A')) or 
            (i == ord(str1[i]) - ord('a'))): 
            count_chars += 1
    return count_chars 
def count_char_position(str1):
    count_chars = 0
    i = 0
    while i < len(str1):
       
        if (i == ord(str1[i]) - ord("A")) or (i == ord(str1[i]) - ord("a")):
            count_chars += 1
        i += 1
    return count_chars