#include using namespace std; int main(){ int n, a, b; cin >> n; cout << 1 << " " << (n - 1) << endl; }