CF1408G Clusterization Counting
Description
There are $ n $ computers in the company network. They are numbered from $ 1 $ to $ n $ .
For each pair of two computers $ 1 \leq i < j \leq n $ you know the value $ a_{i,j} $ : the difficulty of sending data between computers $ i $ and $ j $ . All values $ a_{i,j} $ for $ i
Input Format
N/A
Output Format
N/A
Explanation/Hint
Here are all possible ways to separate all computers into $ 4 $ groups in the second example:
- $ \{1, 2\}, \{3, 4\}, \{5\}, \{6, 7\} $ ;
- $ \{1\}, \{2\}, \{3, 4\}, \{5, 6, 7\} $ ;
- $ \{1, 2\}, \{3\}, \{4\}, \{5, 6, 7\} $ .