Definition at line 18 of file main.cpp.
◆ Solution()
Definition at line 24 of file main.cpp.
25 {
28 while (ptr != NULL)
29 {
32 }
34 ptr = head;
35 for (
int i = 0; i <
length; ++i)
36 {
37 (*array)[i] = ptr;
39 }
40 srand(time(NULL));
41 }
vector< ListNode * > * array
Definition for singly-linked list.
References array, length, and ListNode::next.
◆ ~Solution()
◆ getRandom()
| int Solution::getRandom |
( |
| ) |
|
|
inline |
◆ array
◆ length
The documentation for this class was generated from the following file: