Again, we have some answers here that do not have a leetcode counterpart, as their linked list implementation does not allow for cycles or intersections. In these problems, i changed the next node definition to the Option<Rc<RefCell<ListNode>>> type - which'll allow for an implementation on these problems. Likewise, i also implemented some test cases to assert the implementation compiles and works.
This PR closes issue #20 with tested solutions.
Again, we have some answers here that do not have a leetcode counterpart, as their linked list implementation does not allow for cycles or intersections. In these problems, i changed the
next
node definition to theOption<Rc<RefCell<ListNode>>>
type - which'll allow for an implementation on these problems. Likewise, i also implemented some test cases to assert the implementation compiles and works.