toString() - Convert numbers to string
Wed Jan 08 2020 19:00:00 GMT+0000 (Coordinated Universal Time)
Saved by @goblindoom95 #javascript #numbers #jsfunctions
line 1: assign a number value to the variable x line 4: convert value of x to string using the toString() method and store it in a new variable y. line 6: convert value of x to string using the toString() directly on numbers line 10: convert value of x to string using the toString() directly on mathematical expressions. NOTE: it is not necessary to store the value of toString() in a new variable.
Comments