{"id":37599,"date":"2017-04-11T15:37:02","date_gmt":"2017-04-11T20:37:02","guid":{"rendered":"https:\/\/kenscourses.com\/tc1014winter2017\/?p=37599"},"modified":"2017-04-11T15:51:28","modified_gmt":"2017-04-11T20:51:28","slug":"wsq11-go-bananas","status":"publish","type":"post","link":"https:\/\/kenscourses.com\/tc1014winter2017\/instructor\/wsq11-go-bananas\/","title":{"rendered":"WSQ11 &#8211; Go Bananas"},"content":{"rendered":"<h2>What To Do<\/h2>\n<p>Write a function called find_bananas which receives a single parameter called filename (a string) and returns a positive integer which is the number of times the word (string) &#8220;banana&#8221; \u00a0(or &#8220;BANANA&#8221; ) is found in the file. The banana can be any case (&#8216;BaNana&#8217; or &#8216;BANANA&#8217; or &#8216;banana&#8217;, etc) and they can be \u201cstuck together\u201d like \u201cbanAnaBANANA\u201d (that counts as two). Create your own test file (plain text) to check your work.<\/p>\n<h2>What to Submit<\/h2>\n<p>As usual, create a blog post explaining what you did, where you found resources (books, videos, web pages, friends) to help you solve this. Remember to put the tag #WSQ11 on your post so our blog hub picks that up.<\/p>\n<p>You should include your code as a link to GitHub.<\/p>\n<p>And of course, leave any questions here as well as asking those questions in our Slack channel so we all see your question posted there.<\/p>\n<h2>Feature Image Credit<\/h2>\n<figure id=\"attachment_37607\" aria-describedby=\"caption-attachment-37607\" style=\"width: 640px\" class=\"wp-caption alignnone\"><a href=\"https:\/\/www.flickr.com\/photos\/cleberquadros\/3834587963\/\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-37607\" src=\"https:\/\/kenscourses.com\/tc1014winter2017\/wp-content\/uploads\/2017\/04\/3834587963_a357e5ae24_z.jpg\" alt=\"&lt;a title=&quot;Colored Bananas&quot; href=&quot;https:\/\/flickr.com\/photos\/cleberquadros\/3834587963&quot;&gt;Colored Bananas&lt;\/a&gt; flickr photo by &lt;a href=&quot;https:\/\/flickr.com\/people\/cleberquadros&quot;&gt;Cleber Quadros&lt;\/a&gt; shared under a &lt;a href=&quot;https:\/\/creativecommons.org\/licenses\/by-nc\/2.0\/&quot;&gt;Creative Commons (BY-NC) license&lt;\/a&gt; &lt;\/small&gt;\" width=\"640\" height=\"480\" srcset=\"https:\/\/kenscourses.com\/tc1014winter2017\/wp-content\/uploads\/2017\/04\/3834587963_a357e5ae24_z.jpg 640w, https:\/\/kenscourses.com\/tc1014winter2017\/wp-content\/uploads\/2017\/04\/3834587963_a357e5ae24_z-300x225.jpg 300w, https:\/\/kenscourses.com\/tc1014winter2017\/wp-content\/uploads\/2017\/04\/3834587963_a357e5ae24_z-144x108.jpg 144w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/a><figcaption id=\"caption-attachment-37607\" class=\"wp-caption-text\"><a title=\"Colored Bananas\" href=\"https:\/\/flickr.com\/photos\/cleberquadros\/3834587963\">Colored Bananas<\/a> flickr photo by <a href=\"https:\/\/flickr.com\/people\/cleberquadros\">Cleber Quadros<\/a> shared under a <a href=\"https:\/\/creativecommons.org\/licenses\/by-nc\/2.0\/\">Creative Commons (BY-NC) license<\/a><\/figcaption><\/figure>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>What To Do Write a function called find_bananas which receives a single parameter called filename (a string) and returns a positive integer which is the number of times the word (string) &#8220;banana&#8221; \u00a0(or &#8220;BANANA&#8221; ) is found in the file. The banana can be any case (&#8216;BaNana&#8217; or &#8216;BANANA&#8217; or &#8216;banana&#8217;, etc) and they can &hellip; <a href=\"https:\/\/kenscourses.com\/tc1014winter2017\/instructor\/wsq11-go-bananas\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">WSQ11 &#8211; Go Bananas<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":37607,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[17,24],"tags":[],"class_list":["post-37599","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-instructor","category-wsq"],"_links":{"self":[{"href":"https:\/\/kenscourses.com\/tc1014winter2017\/wp-json\/wp\/v2\/posts\/37599","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/kenscourses.com\/tc1014winter2017\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/kenscourses.com\/tc1014winter2017\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/kenscourses.com\/tc1014winter2017\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/kenscourses.com\/tc1014winter2017\/wp-json\/wp\/v2\/comments?post=37599"}],"version-history":[{"count":2,"href":"https:\/\/kenscourses.com\/tc1014winter2017\/wp-json\/wp\/v2\/posts\/37599\/revisions"}],"predecessor-version":[{"id":37608,"href":"https:\/\/kenscourses.com\/tc1014winter2017\/wp-json\/wp\/v2\/posts\/37599\/revisions\/37608"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/kenscourses.com\/tc1014winter2017\/wp-json\/wp\/v2\/media\/37607"}],"wp:attachment":[{"href":"https:\/\/kenscourses.com\/tc1014winter2017\/wp-json\/wp\/v2\/media?parent=37599"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/kenscourses.com\/tc1014winter2017\/wp-json\/wp\/v2\/categories?post=37599"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/kenscourses.com\/tc1014winter2017\/wp-json\/wp\/v2\/tags?post=37599"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}