CF436C: Minimum Spanning Tree