def kthPrimeNumber(self, k):
        """
        heap and queue

        :param k:
        :return:
        """
        import heapq

        h1 = QueueNode(3)
        h2 = QueueNode(5)
        h3 = QueueNode(7)

        heap = [h1, h2, h3]
        heapq.heapify(heap)

        for cnt in xrange(1-k):
            h = heapq.heappop(heap)
            if h == h1:
                h1.q.append(h1.val*3)
                h2.q.append(h1.val*5)
                h3.q.append(h1.val*7)
            elif h == h2:
                h2.q.append(h2.val*5)
                h3.q.append(h2.val*7)
            else:
                h3.q.append(h3.val*7)

            h.next()
            heapq.heappush(heap, h)

        return heapq.heappop(heap).val
dataset/ETHPy150Open algorhythms/LintCode/Kth Prime Number.py/Solution.kthPrimeNumber/swapped operands of `-`