Given two version strings version1 and version2, compare them. Return -1 if version1 < version2, 1 if version1 > version2, and 0 if equal. Each version is dot-separated integers; ignore leading zeros and treat missing trailing revisions as 0. Input: '"v1", "v2"'.
Input: '"v1", "v2"'.
Output: Integer — -1, 0, or 1.
Input: "1.01", "1.001"
Output: 0
Explanation: Both equal 1.1 numerically.Input: "1.0", "1.0.0"
Output: 0
Explanation: Trailing zeros ignored.Input: "0.1", "1.1"
Output: -1
Explanation: 0 < 1.1<=version length<=500valid version format