Shichikuji and Power Grid
Source: Codeforces 1245D
- Read the problem and summarise the task requirements.
- Try to keep your response to a couple of sentences.
- Identify the graph in the problem, and which famous graph problem is most similar to the problem we have to solve.
- What distinguishes our problem from the famous problem?
It is not typical to combine vertex weights and edge weights.
Perform a construction to associate the cost of building a power station to an edge rather than a vertex.
Design an algorithm to solve the problem.
Analyse the time complexity of your algorithm and estimate its running time.
- Implement this algorithm in code.
- Reflector:
- What potential pitfalls can you think of?
- Write some tests to check for these pitfalls.
- Other group members:
- Write a program which solves the problem.
- Run your tests and debug if necessary.
- Submit your program for judging!