calculating node with highest in degree