{"action":"created","issue":{"url":"https://api.github.com/repos/accesscode-2-1/unit-0/issues/6","labels_url":"https://api.github.com/repos/accesscode-2-1/unit-0/issues/6/labels{/name}","comments_url":"https://api.github.com/repos/accesscode-2-1/unit-0/issues/6/comments","events_url":"https://api.github.com/repos/accesscode-2-1/unit-0/issues/6/events","html_url":"https://github.com/accesscode-2-1/unit-0/issues/6","id":64959438,"number":6,"title":"HW due 4/3","user":{"login":"asaini","id":1134064,"avatar_url":"https://avatars.githubusercontent.com/u/1134064?v=3","gravatar_id":"","url":"https://api.github.com/users/asaini","html_url":"https://github.com/asaini","followers_url":"https://api.github.com/users/asaini/followers","following_url":"https://api.github.com/users/asaini/following{/other_user}","gists_url":"https://api.github.com/users/asaini/gists{/gist_id}","starred_url":"https://api.github.com/users/asaini/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/asaini/subscriptions","organizations_url":"https://api.github.com/users/asaini/orgs","repos_url":"https://api.github.com/users/asaini/repos","events_url":"https://api.github.com/users/asaini/events{/privacy}","received_events_url":"https://api.github.com/users/asaini/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":9,"created_at":"2015-03-28T16:14:40Z","updated_at":"2015-04-03T15:48:36Z","closed_at":null,"body":"Welcome to HW4! This homework is due on Friday, 4/3 by 8 pm.\r\n\r\n### 1. Linear Search on ArrayList \r\nYou are given an ArrayList of unknown size containing integers. Write a class called **LinearSearch** which implements a static method **search** which accepts as input an ArrayList **alist** and an integer **x**, and returns the first index it sees of **x** in **alist**. If the integer is not present return in the list return -1\r\n\r\n    Eg. if arraylist contains: [3, 45, 1, 2, 99] and x = 1\r\n    Returns : 2\r\n\r\n### 2. Sanitizing web pages\r\nSearch engines like Google have programs called [web-scapers](http://en.wikipedia.org/wiki/Web_scraping) which visit webpages and scrape the information *displayed* on the webpage. The displayable information is contained in html tags like *p*, *table*, *h2* etc. When we make a GET request for a webpage, the HTML that is returned can also contain tags like **_script_** which often do not correspond to the displayable content on the webpage. Information inside _script_ tags is not used by scapers and they often ignore these tags in the HTML. Write a class called **WebPageSanitizer** which implements a static method called *String sanitize(String html)* which removes all script tags and the information that they encapsulate and returns a *sanitized* version of the HTML string.\r\n\r\n### 3. Character Distributions\r\nCreate a class to calculate the distribution of characters in the contents of a text file. Your class called **DistributionCalculator** should implement a method *calculate(File textFile)* which accepts as input a Text file. It reads the contents of the file and returns an ArrayList which contains the distribution/percentage of characters (a-z) in the text file. You should lowercase lines before you do the calculation. Call the *calculate* method from main and print the distribution. You can ignore characters which do not belong in the range(a-z) for doing your calculation. Your program's output should look something like:\r\n\r\n    a = 14.44 %\r\n    b = 6.02 %\r\n    ...\r\n    ...\r\n    z = 0.05 %\r\n\r\n### 4. Bonus/Challenge : Project Euler \r\n[Project Euler](https://projecteuler.net/) is a website dedicated to a series of computational problems intended to be solved with computer programs. The project attracts adults and students interested in mathematics and computer programming.  \r\nAs an exercise, we are asking you to solve one of Project Euler's problems described [here](https://projecteuler.net/problem=17). Create a class called **LettersInNumbers** which has a method **letterCount** which returns an integer containing the number of letters.\r\n\r\n### 5. Weekly Requirements\r\n* **WRITE** a Medium post about something technical or non technical you learned this week\r\n* **TWEET** at least once!  \r\n* **Weekly THINK PIECE** : [Amy Cuddy - Your Body Language Shapes Who You Are](http://www.ted.com/talks/amy_cuddy_your_body_language_shapes_who_you_are?language=en)\r\n\r\nAfter submitting your HW, please complete a [HW Feedback form](https://docs.google.com/forms/d/1uQDPiGA_jmgpf_Lus-kZlestR3SxZBEHlD6GIqYWJAY/viewform?usp=send_form)"},"comment":{"url":"https://api.github.com/repos/accesscode-2-1/unit-0/issues/comments/89334122","html_url":"https://github.com/accesscode-2-1/unit-0/issues/6#issuecomment-89334122","issue_url":"https://api.github.com/repos/accesscode-2-1/unit-0/issues/6","id":89334122,"user":{"login":"AnthonyFermin","id":7085742,"avatar_url":"https://avatars.githubusercontent.com/u/7085742?v=3","gravatar_id":"","url":"https://api.github.com/users/AnthonyFermin","html_url":"https://github.com/AnthonyFermin","followers_url":"https://api.github.com/users/AnthonyFermin/followers","following_url":"https://api.github.com/users/AnthonyFermin/following{/other_user}","gists_url":"https://api.github.com/users/AnthonyFermin/gists{/gist_id}","starred_url":"https://api.github.com/users/AnthonyFermin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AnthonyFermin/subscriptions","organizations_url":"https://api.github.com/users/AnthonyFermin/orgs","repos_url":"https://api.github.com/users/AnthonyFermin/repos","events_url":"https://api.github.com/users/AnthonyFermin/events{/privacy}","received_events_url":"https://api.github.com/users/AnthonyFermin/received_events","type":"User","site_admin":false},"created_at":"2015-04-03T15:48:36Z","updated_at":"2015-04-03T15:48:36Z","body":"1. [Homework](https://github.com/AnthonyFermin/HW-20150403)\r\n2. [Medium](https://medium.com/@fermin_anthony/fried-brain-47c9180a7ec6)"}}