#include <iostream> using namespace std; int main() { int m; cin >> m; cout << m / 13 << "\n" << m % 13; return 0; }