#include <bits/stdc++.h>
using namespace std;
const int maxn = 1e5 + 10;
char str[maxn];
void solve() {
  int len = strlen(str);
  int tot = 0, t2 = 0;
  for (int i = 0; i < len; i++) {
    if (str[i] == '0') {
      cout << 2 << " " << tot + 1 << endl;
      tot = (tot + 1) % 4;
    } else {
      cout << 1 << " " << t2 + 1 << endl;
      t2 = (t2 + 2) % 4;
    }
  }
}
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  ;
  while (cin >> str) solve();
  return 0;
}
