Skip to content

Leetcode 3428. Maximum and Minimum Sums of at Most Size K Subsequences #307

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
Woodyiiiiiii opened this issue Feb 4, 2025 · 0 comments

Comments

@Woodyiiiiiii
Copy link
Owner

3428. Maximum and Minimum Sums of at Most Size K Subsequences

参考资料:

代码就不贴了,主要包括一些固定写法:

  1. pow方法的自定义
  2. 如何预处理n!和(n1!)^(-1),两者之间的转换INV_F[MX - 1] = pow(F[MX - 1], MOD - 2)
  3. 对称,a[i]在sub-sequences为最大值的数目等于a[n - i - 1]在sub-sequences为最小值的数目
  4. 代码完成
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant