AND Maximum Spanning Tree

You have a weighted undirected complete graph of NNN nodes numbered from 000 to N−1N-1N−1. The weight of the edge between node AAA and BBB is defined as AAA&BBB (where & denotes bitwise AND operation). Can you find the cost of the maximum spanning tree of this graph ?


This is a companion discussion topic for the original entry at https://toph.co/p/and-maximum-spanning-tree