#include <bits/stdc++.h>
using namespace std;
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  string s;
  cin >> s;
  long long int h = 0, v = 0;
  vector<pair<long long int, long long int>> ans(s.length());
  for (long long int i = 0; i < s.length(); i++) {
    if (s[i] == '0') {
      ans[i] = {3, v + 1};
      v++;
    } else {
      if (h == 0)
        ans[i] = {1, h + 1};
      else {
        ans[i] = {1, h + 2};
      }
      h++;
    }
    v %= 4;
    h %= 2;
  }
  for (long long int i = 0; i < s.length(); i++) {
    cout << ans[i].first << " " << ans[i].second << endl;
  }
}
