QOJ.ac

QOJ

时间限制: 3 s 内存限制: 512 MB 总分: 100

#834. 不相交的 LIS

统计

令一个排列的 LIS 为其最长上升子序列的长度。

如果一个排列能够找到两条长度均为 LIS 且不包含任何公共元素的上升子序列,则称该排列是“好的”(good)。

给定 $n$,求有多少个包含 $n$ 个元素的“好的”排列。由于答案可能很大,你只需要输出其对 $998\,244\,353$ 取模的结果。

输入格式

输入的第一行包含一个整数 $n$ ($1 \le n \le 75$):元素的个数。

输出格式

输出一个整数:包含 $n$ 个元素的“好的”排列的数量,对 $998\,244\,353$ 取模。

样例

样例输入 1

6

样例输出 1

132

Discussions

About Discussions

The discussion section is only for posting: General Discussions (problem-solving strategies, alternative approaches), and Off-topic conversations.

This is NOT for reporting issues! If you want to report bugs or errors, please use the Issues section below.

Open Discussions 0
No discussions in this category.

Issues

About Issues

If you find any issues with the problem (statement, scoring, time/memory limits, test cases, etc.), you may submit an issue here. A problem moderator will review your issue.

Guidelines:

  1. This is not a place to publish discussions, editorials, or requests to debug your code. Issues are only visible to you and problem moderators.
  2. Do not submit duplicated issues.
  3. Issues must be filed in English or Chinese only.
Active Issues 0
No issues in this category.
Closed/Resolved Issues 0
No issues in this category.