Skip to content

Commit a02df76

Browse files
committed
Update test.cpp
1 parent b1b6da6 commit a02df76

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

split-a-circular-linked-list/test.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,9 +108,10 @@ TEST(split_a_circular_linked_list, test2)
108108
auto input = vector<int> { 2, 6, 1, 5 };
109109
auto output = vector<vector<int>> { { 2, 6 }, { 1, 5 } };
110110
auto* list = ArrayToCircularLinkedList(input);
111-
auto result = Solution().splitCircularLinkedList(list) | transform(CircularLinkedListToArray);
111+
112112
auto nodes = unordered_set<ListNode*> {};
113113
TraversalCircularListNode(list, [&](auto* node) { nodes.insert(node); });
114+
auto result = Solution().splitCircularLinkedList(list) | transform(CircularLinkedListToArray);
114115
assertContentEquals(result, output);
115116
for (auto* node : nodes) {
116117
delete node;

0 commit comments

Comments
 (0)