{"action":"created","issue":{"url":"https://api.github.com/repos/learn-co-curriculum/iterators-and-abstraction-ruby/issues/16","labels_url":"https://api.github.com/repos/learn-co-curriculum/iterators-and-abstraction-ruby/issues/16/labels{/name}","comments_url":"https://api.github.com/repos/learn-co-curriculum/iterators-and-abstraction-ruby/issues/16/comments","events_url":"https://api.github.com/repos/learn-co-curriculum/iterators-and-abstraction-ruby/issues/16/events","html_url":"https://github.com/learn-co-curriculum/iterators-and-abstraction-ruby/issues/16","id":117685910,"number":16,"title":"Are these example methods wrong? ","user":{"login":"fullstack212","id":13323449,"avatar_url":"https://avatars.githubusercontent.com/u/13323449?v=3","gravatar_id":"","url":"https://api.github.com/users/fullstack212","html_url":"https://github.com/fullstack212","followers_url":"https://api.github.com/users/fullstack212/followers","following_url":"https://api.github.com/users/fullstack212/following{/other_user}","gists_url":"https://api.github.com/users/fullstack212/gists{/gist_id}","starred_url":"https://api.github.com/users/fullstack212/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fullstack212/subscriptions","organizations_url":"https://api.github.com/users/fullstack212/orgs","repos_url":"https://api.github.com/users/fullstack212/repos","events_url":"https://api.github.com/users/fullstack212/events{/privacy}","received_events_url":"https://api.github.com/users/fullstack212/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-11-18T21:29:36Z","updated_at":"2015-12-15T23:39:43Z","closed_at":"2015-12-15T23:39:43Z","body":"Wouldn't this example method stop removing apples from the basket when there were 5 apples in the basket and 5 taken out instead of continuing until all the apples were removed from the basket?  Because at that point the condition for continuing to iterate would be false---5 is not less than 5.  Or am I just misunderstanding something?  Thanks! \r\n\r\nbasket = [\"apple 1\",\"apple 2\",\"apple 3\",\"apple 4\",\"apple 5\",\"apple 6\",\"apple 7\",\"apple 8\",\"apple 9\",\"apple 10\"]\r\n\r\napples_in_basket = basket.size # Step 1\r\napples_taken_out = 0 # Step 2\r\n\r\nloop do # Step 3\r\n    if apples_taken_out < apples_in_basket \r\n        # Step 4\r\n        puts \"Taking out #{basket[apples_taken_out]}\"\r\n        apples_taken_out += 1\r\n    else\r\n        # Step 5\r\n        break\r\n    end\r\nend"},"comment":{"url":"https://api.github.com/repos/learn-co-curriculum/iterators-and-abstraction-ruby/issues/comments/164936759","html_url":"https://github.com/learn-co-curriculum/iterators-and-abstraction-ruby/issues/16#issuecomment-164936759","issue_url":"https://api.github.com/repos/learn-co-curriculum/iterators-and-abstraction-ruby/issues/16","id":164936759,"user":{"login":"AnnJohn","id":1892150,"avatar_url":"https://avatars.githubusercontent.com/u/1892150?v=3","gravatar_id":"","url":"https://api.github.com/users/AnnJohn","html_url":"https://github.com/AnnJohn","followers_url":"https://api.github.com/users/AnnJohn/followers","following_url":"https://api.github.com/users/AnnJohn/following{/other_user}","gists_url":"https://api.github.com/users/AnnJohn/gists{/gist_id}","starred_url":"https://api.github.com/users/AnnJohn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AnnJohn/subscriptions","organizations_url":"https://api.github.com/users/AnnJohn/orgs","repos_url":"https://api.github.com/users/AnnJohn/repos","events_url":"https://api.github.com/users/AnnJohn/events{/privacy}","received_events_url":"https://api.github.com/users/AnnJohn/received_events","type":"User","site_admin":false},"created_at":"2015-12-15T23:39:43Z","updated_at":"2015-12-15T23:39:43Z","body":"Hi @fullstack212 sorry for the delay on this. If you still have questions on this or any other lab, use the Ask a Question tool in Learn and someone from our Learn support team will get back to you. Thanks!"}}