String Parsing

Strings cannot be directly converted to another data type, but strings can represent…

What does it mean to parse a string?

Strings cannot be directly converted to another data type, but strings can represent various data types.

Parsing a string is the process of iterating through it's characters and transforming the string into a different type.

// parseInt and parseFloat are global in JavaScript
let age = parseInt("24");
let price = parseFloat("3.95");

Level: Apprentice · More JavaScript terms at this level

Updated