Guest User

Untitled

a guest
Nov 16th, 2018
140
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.93 KB | None | 0 0
  1. # Task
  2. Write a javascript function which takes the text in the html file and outputs a list with all words from the text and the count of their occurrences, ordered by the occurrences.
  3.  
  4. The result is in the `result.html`.
  5.  
  6. # Rules
  7. - Read the rules carefully and act according to them.
  8. - No external libararies.
  9. - Please use 2 spaces for indentation, no tabs.
  10. - Don't pollute the global namespace, don't leak any variables.
  11. - Send the result as a github gist like this file.
  12. - Stop immediately after 15 minutes - we don't need, want or honor a working solution, we are interested in your approach.
  13. - Put your code in the `index.html` file inside the `script` tag in line 58.
  14. - The code should work on the latest Chrome version.
  15. - Add a brief description (~ three bullet points) on how you would test your code.
  16.  
  17. # My comments on testing
  18. - unit test which tests regular expressions on correct parsing
  19. - UI test which tests that the result has been rendereded
Add Comment
Please, Sign In to add comment