The parseInt() Method

Number.parseInt() converts strings to whole numbers: