You are given a string s of length n. Does a tree with n vertices that satisfies the following conditions exist?

* The vertices are numbered 1,2,..., n.
* The edges are numbered 1,2,..., n-1, and Edge i connects Vertex u_i and v_i.
* If the i-th character in s is `1`, we can have a connected component of size i by removing one edge from the tree.
* If the i-th character in s is `0`, we cannot have a connected component of size i by removing any one edge from the tree.



If such a tree exists, construct one such tree.

Constraints

* 2 \leq n \leq 10^5
* s is a string of length n consisting of `0` and `1`.

Input

Input is given from Standard Input in the following format:


s


Output

If a tree with n vertices that satisfies the conditions does not exist, print `-1`.

If a tree with n vertices that satisfies the conditions exist, print n-1 lines. The i-th line should contain u_i and v_i with a space in between. If there are multiple trees that satisfy the conditions, any such tree will be accepted.

Examples

Input

1111


Output

-1


Input

1110


Output

1 2
2 3
3 4


Input

1010


Output

1 2
1 3
1 4
#!/usr/bin/env python3
# -*- coding: utf-8 -*-

# 必要条件まではわかったけど、必ず任意の木を構築できる
# という考えには至らず。
# https://betrue12.hateblo.jp/entry/2018/09/30/125042
# の図とC++コードを参考にする
#
# まず1文字目は必ず1。最初は以下のようなエッジを構築。
#                 2(top)
#                /
#               1
# "top"は、つぎの頂点がつながる先を表す。
#
# 2文字目が0の場合:  topは移動しない
#                 2(top)
#                / \
#               1   3
# 2文字目が1の場合:  topは移動する
#                   3(top)
#                  /
#                 2
#                /
#               1


import array
from bisect import *
from collections import *
import fractions
import heapq
from itertools import *
import math
import random
import re
import string
import sys

def solve(S):
    # 必要条件の確認
    if S[-1] == '1':
        return -1
    if S[0] == '0':
        return -1
    size = len(S)
    i = 0
    j = size - 2
    while i < j:
        if S[i] != S[j]:
            return -1
        i += 1
        j -= 1

    # ここまで来た場合は必ず木を構築可能
    edges = []
    top = 0
    for i in range(size - 1):
        edges.append((top, i + 1))
        if S[i] == '1': 
            top = i + 1
    return edges

S = input()
ans = solve(S)
if ans == -1:
    print(ans)
else:
    for e in ans:
        print("{} {}".format(e[0] + 1, e[1] + 1))

