Given a non-negative integer represented as a linked list of digits with the most significant digit first, return the linked list representing twice that number (also most significant digit first). Return the result as an array.
Input: An array of digits (MSB first).
Output: Array — the doubled number's digits.
Input: [1,8,9]
Output: [3,7,8]
Explanation: 189 * 2 = 378.Input: [9,9,9]
Output: [1,9,9,8]
Explanation: 999 * 2 = 1998.Input: [0]
Output: [0]
Explanation: 0 * 2 = 0.1<=n<=10^4digit in 0..9no leading zeros except 0