Hi guys I am really stuck in this one situation :S I have a local .txtfile with a random sentence and my program is meant to :
I am finding it difficult to execute the third question. My code is ..
JavaScript
      lengths.forEach((leng) => {
      counter[leng] = counter[leng] || 0;
      counter[leng]++;
});     
      $("#display_File_most").text(counter);
     }
    }          
        r.readAsText(f);
    }
});
  </script> 
I have used this question for help but no luck - Using Javascript to find most common words in string?
I believe I have to store the sentence in an array and loop through it, uncertain if that is the correct step or if there is quicker way of finding the solution so I ask you guys.
Thanks for your time & I hope my question made sense :)
 
     
     
    