{"action":"created","issue":{"url":"https://api.github.com/repos/kclauser/assignments/issues/2","labels_url":"https://api.github.com/repos/kclauser/assignments/issues/2/labels{/name}","comments_url":"https://api.github.com/repos/kclauser/assignments/issues/2/comments","events_url":"https://api.github.com/repos/kclauser/assignments/issues/2/events","html_url":"https://github.com/kclauser/assignments/issues/2","id":103064161,"number":2,"title":"Assignment 1-2 - User Input Statistics","user":{"login":"gstark","id":2607,"avatar_url":"https://avatars.githubusercontent.com/u/2607?v=3","gravatar_id":"","url":"https://api.github.com/users/gstark","html_url":"https://github.com/gstark","followers_url":"https://api.github.com/users/gstark/followers","following_url":"https://api.github.com/users/gstark/following{/other_user}","gists_url":"https://api.github.com/users/gstark/gists{/gist_id}","starred_url":"https://api.github.com/users/gstark/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gstark/subscriptions","organizations_url":"https://api.github.com/users/gstark/orgs","repos_url":"https://api.github.com/users/gstark/repos","events_url":"https://api.github.com/users/gstark/events{/privacy}","received_events_url":"https://api.github.com/users/gstark/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":{"login":"kclauser","id":13937315,"avatar_url":"https://avatars.githubusercontent.com/u/13937315?v=3","gravatar_id":"","url":"https://api.github.com/users/kclauser","html_url":"https://github.com/kclauser","followers_url":"https://api.github.com/users/kclauser/followers","following_url":"https://api.github.com/users/kclauser/following{/other_user}","gists_url":"https://api.github.com/users/kclauser/gists{/gist_id}","starred_url":"https://api.github.com/users/kclauser/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kclauser/subscriptions","organizations_url":"https://api.github.com/users/kclauser/orgs","repos_url":"https://api.github.com/users/kclauser/repos","events_url":"https://api.github.com/users/kclauser/events{/privacy}","received_events_url":"https://api.github.com/users/kclauser/received_events","type":"User","site_admin":false},"milestone":null,"comments":3,"created_at":"2015-08-25T16:22:20Z","updated_at":"2015-08-26T23:18:36Z","closed_at":null,"body":"## Description\n\nCreate a program which will take repeated input from the user and generate statistics on those inputs.\n\n## Objectives\n\nAfter completing this assignment, you should...\n\n* Understand control flow, specifically looping and branching.\n* Understand variables and data types.\n* Understand basic ways in which a Ruby program can present information to the user and request information from the user.\n* Understand how ruby code resides on the file system.\n* Be able to use `puts` and `gets`.\n* Be able to perform calculations on variables.\n* Be able to run ruby code from the command line.\n\n## Deliverables\n\n* **Ruby code.** This code should be executable, should run without errors, and should accomplish the requirements given below. Try to keep to the ruby style guide as you code.\n* **A link to a Gist.** Create a Ruby Gist on http://gist.github.com and paste your Ruby code into it. Run your code in the command line. Running this with `atom-runner` or `seeing is believing` won't work for us because we are interacting with the user. Submit the link to this gist via the homework submission form found on the course website.\n\n## Normal Mode\n\nYour goal for tonight is to create a program to keep track of user input.  You will repeatedly ask the user to enter a number, and as long as the user types a number and hits enter, you will ask again.  If the user hits enter on a blank line (without typing a number first), this means that the user is finished.\n\nOnce the user is finished, you should present statistics about the inputs.  You should give:\n* The total of all the numbers.\n* The average of all the numbers.\n\nYour program should still work if the user inputs negative numbers and/or non-integer rational numbers (e.g. `3.45`).\n\n## Adventure Mode\n\nExtend your program to accept strings as well.  If the user starts off by entering a string (e.g. `correct`), then the program will accept strings for subsequent inputs.  Rather than showing statistics at the end, it will show the concatenated version of the inputs.  For example, if the inputs are the following:\n\n* `correct`\n* `horse`\n* `battery`\n* `staple`\n\nThen the output will be `correcthorsebatterystaple`.\n\nYour program should continue to work exactly like Normal Mode if the user starts by entering a number.  If the user mixes numbers and strings in the same run, your program should tell the user to start over, then stop execution.\n\n## Hard Mode\n\nWhen the user is inputting numbers, add the following statistics to the output:\n\n* Standard Deviation\n* Median\n\nWhen the user is inputting strings, add the following statistics to the output:\n\n* Average length of inputs\n* Number of times the letter `e` was used in the inputs.\n"},"comment":{"url":"https://api.github.com/repos/kclauser/assignments/issues/comments/135203483","html_url":"https://github.com/kclauser/assignments/issues/2#issuecomment-135203483","issue_url":"https://api.github.com/repos/kclauser/assignments/issues/2","id":135203483,"user":{"login":"gstark","id":2607,"avatar_url":"https://avatars.githubusercontent.com/u/2607?v=3","gravatar_id":"","url":"https://api.github.com/users/gstark","html_url":"https://github.com/gstark","followers_url":"https://api.github.com/users/gstark/followers","following_url":"https://api.github.com/users/gstark/following{/other_user}","gists_url":"https://api.github.com/users/gstark/gists{/gist_id}","starred_url":"https://api.github.com/users/gstark/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gstark/subscriptions","organizations_url":"https://api.github.com/users/gstark/orgs","repos_url":"https://api.github.com/users/gstark/repos","events_url":"https://api.github.com/users/gstark/events{/privacy}","received_events_url":"https://api.github.com/users/gstark/received_events","type":"User","site_admin":false},"created_at":"2015-08-26T23:18:36Z","updated_at":"2015-08-26T23:18:36Z","body":"![Awesome Work!](http://s3.amazonaws.com/giphygifs/media/ykAWwKmzL40ta/200w_d.gif)"}}