DEV Community

Discussion on: JavaScript Katas: Higher Version

Collapse
 
westim profile image
Tim West

With the assumption that the two versions are the same length and have no leading zeros, yes. I'd probably recommend .replaceAll('.', '') over split('.').join('').