Round table#11679

Round table

1 second
128 megabytes
Very easy

In how many ways can distinct people be seated around a round table? Two seatings are considered the same if one can be obtained from the other by rotating the table.

Input

One positive integer (n \le 20).

Output

Print the number of distinct ways to seat different people around a round table.

Examples

For people, there are distinct seatings:

  • (1, 2, 3, 4)

  • (1, 2, 4, 3)

  • (1, 3, 2, 4)

  • (1, 3, 4, 2)

  • (1, 4, 2, 3)

  • (1, 4, 3, 2)

All other seatings can be reduced to one of the listed ones by rotation. For example, the seating (4, 2, 1, 3) is equivalent to (1, 3, 4, 2).

Example 1

Loading
Loading