#include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  int n, i, x, y;
  cin >> n;
  y = 0;
  for (i = 3; i <= n; i += 3) ++y;
  if (i == n + 1) ++y;
  x = y / 12;
  y -= x * 12;
  cout << x << " " << y << "\n";
  return 0;
}
