File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -103,7 +103,7 @@ static void test() {
103
103
}
104
104
temp->next = nullptr ;
105
105
106
- ListNode* median = search::median_search2::middleNode (head1);
106
+ const ListNode* const median = search::median_search2::middleNode (head1);
107
107
assert (3 == median->val ); // 3 is the value of the median node.
108
108
search::median_search2::deleteAll (head1);
109
109
std::cout << " test case:1 passed\n " ;
@@ -124,7 +124,7 @@ static void test() {
124
124
}
125
125
temp2->next = nullptr ;
126
126
127
- ListNode* median1 = search::median_search2::middleNode (head2);
127
+ const ListNode* const median1 = search::median_search2::middleNode (head2);
128
128
assert (4 == median1->val ); // 4 is the value of the median node.
129
129
search::median_search2::deleteAll (head2);
130
130
std::cout << " test case:2 passed\n " ;
You can’t perform that action at this time.
0 commit comments