How to add up numbers from 1 to N using japascript and a FOR LOOP : This is the code I have currently, but it doesn't work! What's the problem with it? It SHOULD add all numbers from 1 to the base_number, but the code is not working. I am trying to learn how to code from the basics up. Thanks so much!

        function start(){
            var base_number = readInt("What is the base number? ");
            function adding();
        }

        function adding(){
            var sum = 0;
            for (var i = 1; i < base_number + 1; i++){
                sum += i;
            }
            return sum;
            println(sum);
        }
