const strNum = "42";
const num = Number(strNum);   // string -> number
const str = String(123);      // number -> string
const bool = Boolean(0);      // 0 -> false

console.log(num, typeof num);
console.log(str, typeof str);
console.log(bool, typeof bool);

// Implicit conversion
console.log("5" + 2); // "52"  (number to string)
console.log("5" - 2); // 3     (string to number)