QOJ.ac

QOJ

Time Limit: 3 s Memory Limit: 512 MB Total points: 100 Difficulty: [show]

#1836. Glory Graph

الإحصائيات

题解 by @ezoilearner,你可以通过以下联系方式联系作者:

  • QQ: 2939863838

题意:给一个完全图,每条边要么是蓝色,要么是黄色。

定义 $A$ 为四个点的生成子图,满足其中五条边颜色一样剩下一条边颜色不一样,的个数。

定义 $B$ 为四个点的生成子图,满足不同颜色数五五开,且不会有个颜色形成同色三角形,的个数。

求 $A-B$ .

$n\leq 2000$

题解:计算两种情况的数量

2 $\times$ 一种颜色的边形成了十字架 $+$ 一种颜色的边恰有一种(即 $A$ )

4 $\times$ 一种颜色的边形成了十字架 $+$ 2 $\times$ B

时间复杂度 $O(\frac{n^3}{w})$

About Issues

We understand that our problem archive is not perfect. If you find any issues with the problem, including the statement, scoring configuration, time/memory limits, test cases, etc.

You may use this form to submit an issue regarding the problem. A problem moderator will review your issue and proceed it properly.

STOP! Before you submit an issue, please READ the following guidelines:

  1. This is not a place to publish a discussion, editorial, or requests to debug your code. Your issue will only be visible by you and problem moderators. Other users will not be able to view or reply your issues.
  2. Do not submit duplicated issues. If you have already submitted one, please wait for an moderator to review it. Submitting multiple issues will not speed up the review process and might cause your account to be banned.
  3. Issues must be filed in English or Chinese only.
  4. Be sure your issue is related to this problem. If you need to submit an issue regarding another problem, contest, category, etc., you should submit it to the corresponding page.

Active Issues 0

No issues in this category.

Closed/Resolved Issues 0

No issues in this category.