#include <bits/stdc++.h>
using namespace std;
string s;
long long x, y;
int main() {
  getline(cin, s);
  s = " " + s;
  for (register int i = 1; i < s.length(); i++)
    if (s[i] == '0') {
      printf("1 %lld\n", ++x);
      x %= 4;
    } else {
      printf("4 %lld\n", ++y);
      y = (y + 1) % 4;
    }
  return 0;
}
