Skip to content

Instantly share code, notes, and snippets.

@niraj-shah
Created January 3, 2013 11:13
Show Gist options
  • Save niraj-shah/4442713 to your computer and use it in GitHub Desktop.
Save niraj-shah/4442713 to your computer and use it in GitHub Desktop.
Create an array to store our result
var text = $('#text').text();
var word_array = text.split(' ');
// blank array to store result
var word_count = {};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment