Delphi.DeepEqualsTemplate
Here is the template for deep equals of objects through rtti. You can expand it or customize
unit DeepEquals; interface uses classes, rtti; type TObjectHelpers
Here is the template for deep equals of objects through rtti. You can expand it or customize
unit DeepEquals; interface uses classes, rtti; type TObjectHelpers
I used neon library, below the example
here is github of my test of this library, lib works nice !!!
how to use? download sources
optimal solution
public ListNode Reverse(ListNode head){ var node = head; ListNode prev = null; while(node != null){ var next = node.next; node.next = prev;
To avoid border cases we can create a fake or how it is called sentinel node
public void DoSmth(ListNode head) { ListNode fakeNode = new
basic approach is to change connection node.next = node.next.next
1. RemoveElements(ListNode head, int val)
leetcode task
optimal solution through sentinel or fake node