#include <bits/stdc++.h>
using namespace std;
int setbit(int n, int pos) { return n = n | (1 << pos); }
int resetbit(int n, int pos) { return n = n & ~(1 << pos); }
bool checkbit(int n, int pos) { return (bool)(n & (1 << pos)); }
template <typename T>
void print(const T& v) {
  cerr << v << ' ';
}
template <typename T1, typename... T2>
void print(const T1& first, const T2&... rest) {
  print(first);
  print(rest...);
}
const long long mod = 1e9 + 7;
const int M = 1000004;
const long long inf = 999999999;
int main() {
  int n;
  cin >> n;
  if (n <= 2)
    cout << n;
  else
    cout << "1";
  return 0;
}
