const는 상수를 의미한다

아래와 같이 값을 변경하려고하면

<script>

    const a = 1;
    a = 2;

    alert(a);


</script>

 

에러가 뜬다

 

아래는 에러가 난 라인이다

 

+ Recent posts