#include <bits/stdc++.h>
int main(void) {
  int i, n, x, f = 0, g = 0;
  scanf("%d", &n);
  x = n;
  for (i = 0; i < n; i++) {
    if (x >= 3) {
      x = x - 3;
      g++;
    }
    if (g == 12) {
      f++;
      g = 0;
    }
  }
  if (x == 2) g++;
  printf("%d %d", f, g);
  return 0;
}
