#include using namespace std; typedef long long ll; ll comb(int n, int k) { if (n == k || k == 0) { return 1; } else { return comb(n - 1, k - 1) + comb(n - 1, k); } } int main() { int x; cin >> x; if (x > 31) { cout << 0 << ' ' << 0 << endl; return 0; } ll count = comb(31, x); ll sum = 0; for (int i = 0;i < 31;i++) { sum += pow(2, i); } sum = count * x / 31 * sum; cout << count << ' ' << sum << endl; return 0; }