<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def available_partitions_for_topic(self, topic):
 """Return set of partitions with known leaders Arguments: topic (str):
 topic to check for partitions Returns: None if topic not found. """

        if topic not in self._partitions:
            return None
        return set([partition for partition, metadata
                              in six.iteritems(self._partitions[topic])
                              if metadata.leader != -1])