n = int(input()) s=input().strip() p = [i+1 for i in range(n)] temp_index = 0 total_len = len(s) for j in range(total_len): if s[j] == "1": p[j], p[temp_index] = p[temp_index], p[j] temp_index = j+1 if temp_index >= n: str_arr = [ str(i) for i in p] print(" ".join(str_arr)) el...