Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR TYPESCRIPT

convert single digit integer into double digit JavaScript

(5).toString().padStart(2,0);  // returns "05"
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #convert #single #digit #integer #double #digit #JavaScript
ADD COMMENT
Topic
Name
4+9 =