需要使用 parseInt 函数的指南

Need Guide to Use the parseInt Function

https://learn.freecodecamp.org/javascript-algorithms-and-data-structures/basic-javascript/use-the-parseint-function/

我需要 Basic 指南 JavaScript - 使用 parseInt 函数(在 freecodecamp)

//You need to declare the function convertToInteger taking a string parameter
//To declare a function, use the function key word and pass in your string parameter
function convertToInteger(str){
     return parseInt(str);
}