#include <bits/stdc++.h>
using namespace std;
const long long MOD = 1e9 + 7;
long long power_mod(long long a, long long b) {
  if (b == 1) return a;
  if (b % 2) return (a * power_mod(a, b - 1)) % MOD;
  long long temp = power_mod(a, b / 2);
  return (temp * temp) % MOD;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  string s;
  cin >> s;
  int h = 0, v = 0;
  for (char c : s) {
    if (c == '0') {
      cout << ((v % 2) * 2) + 1 << " 1\n";
      v++;
    } else {
      cout << ((h % 4)) + 1 << " 3" << '\n';
      h++;
    }
  }
}
