String and Number Conversions

Published by leopetrovic11 in

You need to create two functions to substitute toString() and parseInt(); A function called intToString() that converts integers into strings and a function called stringToInt() that converts strings into integers.

Examples:

intToString(4) ➞ "4"

stringToInt("4") ➞ 4

intToString(29348) ➞ "29348"

Notes

You will get bonus points if you manage to solve this without using toString, parseInt or parseFloat.

Watch a quick demo on how Edabit works.