import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;
public class Main {
public static int res = 0;
@SuppressWarnings("resource")
public static void main(String[] args) {
Scanner scan = new Scanner(System.in);
int n = scan.nextInt();
List<Integer> list = new ArrayList<>();
list.add(1);
dfs(list, 2, n);
System.out.println(res);
}
private static void dfs(List<Integer> list, int next, int n) {
// TODO Auto-generated method stub
// ans
if (next == n + 1) {
++res;
return;
}
// push
list.add(next);
dfs(list, next + 1, n);
list.remove(list.size() - 1);
// pop
if (list.size() > 0) {
int tmp = list.get(list.size() - 1);
list.remove(list.size() - 1);
dfs(list, next, n);
list.add(tmp);
}
}
}