private void unassignedPartitionsAssignment() {
        List<TopicIdPartition> sortedPartitions = sortTopicIdPartitions(unassignedPartitions);

        for (TopicIdPartition partition : sortedPartitions) {
            TreeSet<String> sortedMembers = assignmentManager.sortMembersByAssignmentSize(
                membersPerTopic.get(partition.topicId())
            );

            for (String member : sortedMembers) {
                if (assignmentManager.maybeAssignPartitionToMember(partition, member)) {
                    break;
                }
            }
        }
    }
Allocates the remaining unassigned partitions to members in a balanced manner.
<li> Partitions are sorted to maximize the probability of a balanced assignment. </li>
<li> Sort members in ascending order of their current target assignment sizes
     to ensure the least filled member gets the partition first. </li>
group-coordinator/src/main/java/org/apache/kafka/coordinator/group/assignor/UniformHeterogeneousAssignmentBuilder.java