#include <bits/stdc++.h>
using namespace std;
int main() {
  int k;
  cin >> k;
  cout << 2 << " " << 3 << endl;
  cout << (1 << 17) + k << " " << (1 << 17) << " " << 0 << endl;
  cout << k << " " << (1 << 17) + k << " " << k << endl;
  return 0;
}
