传送门:Dashboard - Codeforces Round 950 (Div. 3) - Codeforces
B. Choosing Cubes(排序)
Dmitry has n cubes, numbered from left to right from 1 to n. The cube with index f is his favorite.
Dmitry threw all the cubes on the table, and the i-th cube showed t…
一、判断的基本结构 if
只有一个if语句,表示如果 ......
语法: if 是python中的关键字,表示如果的意思。判断条件后面的冒号必须要有。冒号后面的代码必须换行缩进,处于if缩进中代码,是if语句代码块,表示…
题目
给你一张 n n n 个点 m m m 条边的无向图,有 p p p 个关键点。你需要选择 k k k 个点染黑,使得这 p p p 个关键点到这 k k k 个黑点的代价和最小。定义代价为两点之间边权最大的边的最小值。 你需要求出 k 1,2,…,n 的所有答案
E1 n,m,p&l…