JSFiddle - React, Tailwind, and code Playground JavaScript var num = 123.4567; num=parseInt(num*100); num=parseFloat(num/100); alert(num);