Given two linked lists, return true if they are identical (same length and same values at each position), false otherwise.
Input: Heads of two singly linked lists.
Output: Boolean true if identical, false otherwise.
Input: [1,2,3], [1,2,3]
Output: true
Explanation: All 3 nodes match. Return true.Input: [1,2,3], [1,2,4]
Output: false
Explanation: 3rd node: 3≠4. Return false.Input: [1,2], [1,2,3]
Output: false
Explanation: Different lengths. Return false.0<=nodes<=10^4-10^9<=Node.val<=10^9