#include <bits/stdc++.h>
using namespace std;
int main() {
  int i, j, x;
  string s;
  cin >> s;
  j = 1;
  x = 3;
  for (i = 0; i < s.size(); i++) {
    if (s[i] == '0') {
      cout << j << " " << 1 << endl;
      ;
      j = j + 2;
      if (j == 5) j = 1;
    } else if (s[i] == '1') {
      cout << "3 " << x << endl;
      x = x - 2;
      if (x == -1) {
        x = 3;
      }
    }
  }
}
