제목 : 예제. 40.내장함수(parseInt및parseFloat함수).htm
<script>
a = "10"
document.write(typeof(a) + "<br>"); //string
document.write(typeof(parseInt(a)) + "<br>"); //number
a = "10.5"
document.write(typeof(a) + "<br>"); //string
document.write(typeof(parseFloat(a)) + "<br>"); //number
document.write(parseInt(a) + "<br>"); //10
document.write(parseFloat(a) + "<br>"); //10.5
</script>