Maximize the Largest Component (Hard Version)

Problem Name:
Maximize the Largest Component (Hard Version)
Site:CodeForces
Links:
Tags:
Problem setters: