import java.io.*;
import java.util.*;
import java.math.*;


public class a {
    BufferedReader in;
    StringTokenizer st;
    PrintWriter out;

    String _token() throws IOException {
        while (in.ready() && !st.hasMoreTokens()) {
            st = new StringTokenizer(in.readLine());
        }
        return st.nextToken();
    }

    int _int() throws NumberFormatException, IOException {
        return Integer.parseInt(_token());
    }

    long _long() throws NumberFormatException, IOException {
        return Long.parseLong(_token());
    }

    double _double() throws NumberFormatException, IOException {
        return Double.parseDouble(_token());
    }

    void deb(String s) {
        System.err.println(s);
    }

    void deb(Object a) {
        System.err.println(a.toString());
    }

    void init(boolean FILE) throws NumberFormatException,
            IOException {
        Locale.setDefault(Locale.US);
        if (FILE) {
            in = new BufferedReader(new FileReader("in"));
            out = new PrintWriter("out");
        } else {
            in = new BufferedReader(new InputStreamReader(System.in));
            out = new PrintWriter(System.out);
        }
        st = new StringTokenizer("");
    }

    void mainProgram() throws NumberFormatException, IOException {
        //      test("a.in");
        init(false);
        int n = _int();
        int a = (n % 3) == 2 ? 1 : 0;
        n += a;
        n/=3;
        a = n/12;
        out.println(a + " "+ (n-12*a));
        out.close();
    }

    int rand(int x) {
        return (int) (Math.random() * x);
    }

    void test(String name) throws IOException {
        out = new PrintWriter(new File(name));

        out.close();
    }

    public static void main(String[] args) throws NumberFormatException,
            IOException {
        long T = System.currentTimeMillis();
        new a().mainProgram();
        System.err.println("Time of working: "
                + (System.currentTimeMillis() - T) + " ms");
    }

    BigInteger add(BigInteger A, BigInteger B) {
        return A.add(B);
    }

    BigInteger mult(BigInteger A, BigInteger B) {
        return A.multiply(B);
    }

    BigInteger sub(BigInteger A, BigInteger B) {
        return A.subtract(B);
    }

    BigInteger div(BigInteger A, BigInteger B) {
        return A.divide(B);
    }

    BigInteger mi(BigInteger A) {
        return (BigInteger.ZERO).subtract(A);
    }

    BigInteger sq(BigInteger A) {
        return A.multiply(A);
    }

    BigInteger val(long a) {
        return BigInteger.valueOf(a);
    }

    int cmp(BigInteger a, BigInteger b) {
        return a.compareTo(b);
    }

}
