mirror of
https://hub.njuu.cf/TheAlgorithms/C-Plus-Plus.git
synced 2023-10-11 13:05:55 +08:00
Update search/median_search2.cpp
Co-authored-by: David Leal <halfpacho@gmail.com>
This commit is contained in:
parent
7c71be9707
commit
da0c875504
@ -22,11 +22,11 @@
|
|||||||
* Definition for singly-linked list.
|
* Definition for singly-linked list.
|
||||||
*/
|
*/
|
||||||
struct ListNode {
|
struct ListNode {
|
||||||
int val; // The value stored in the node
|
int val; ///< the value stored in the node
|
||||||
ListNode *next; // Pointer to the next node
|
ListNode *next; ///< pointer to the next node
|
||||||
ListNode() : val(0), next(nullptr) {} // Default constructor
|
ListNode() : val(0), next(nullptr) {} ///< default constructor
|
||||||
ListNode(int x) : val(x), next(nullptr) {} // Constructor with value for node->val provided
|
ListNode(int x) : val(x), next(nullptr) {} ///< constructor with value for node->val provided
|
||||||
ListNode(int x, ListNode *next) : val(x), next(next) {} // Constructor with values provided for node->val and node->next
|
ListNode(int x, ListNode *next) : val(x), next(next) {} ///< constructor with values provided for node->val and node->next
|
||||||
};
|
};
|
||||||
|
|
||||||
#include <iostream> /// for IO operations
|
#include <iostream> /// for IO operations
|
||||||
|
Loading…
Reference in New Issue
Block a user