Warning: The magic method Slickr_Flickr_Plugin::__wakeup() must have public visibility in /home/kenbauer/public_kenscourses/tc101fall2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php on line 152

Warning: Cannot modify header information - headers already sent by (output started at /home/kenbauer/public_kenscourses/tc101fall2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php:152) in /home/kenbauer/public_kenscourses/tc101fall2015/wp-includes/rest-api/class-wp-rest-server.php on line 1831

Warning: Cannot modify header information - headers already sent by (output started at /home/kenbauer/public_kenscourses/tc101fall2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php:152) in /home/kenbauer/public_kenscourses/tc101fall2015/wp-includes/rest-api/class-wp-rest-server.php on line 1831

Warning: Cannot modify header information - headers already sent by (output started at /home/kenbauer/public_kenscourses/tc101fall2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php:152) in /home/kenbauer/public_kenscourses/tc101fall2015/wp-includes/rest-api/class-wp-rest-server.php on line 1831

Warning: Cannot modify header information - headers already sent by (output started at /home/kenbauer/public_kenscourses/tc101fall2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php:152) in /home/kenbauer/public_kenscourses/tc101fall2015/wp-includes/rest-api/class-wp-rest-server.php on line 1831

Warning: Cannot modify header information - headers already sent by (output started at /home/kenbauer/public_kenscourses/tc101fall2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php:152) in /home/kenbauer/public_kenscourses/tc101fall2015/wp-includes/rest-api/class-wp-rest-server.php on line 1831

Warning: Cannot modify header information - headers already sent by (output started at /home/kenbauer/public_kenscourses/tc101fall2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php:152) in /home/kenbauer/public_kenscourses/tc101fall2015/wp-includes/rest-api/class-wp-rest-server.php on line 1831

Warning: Cannot modify header information - headers already sent by (output started at /home/kenbauer/public_kenscourses/tc101fall2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php:152) in /home/kenbauer/public_kenscourses/tc101fall2015/wp-includes/rest-api/class-wp-rest-server.php on line 1831

Warning: Cannot modify header information - headers already sent by (output started at /home/kenbauer/public_kenscourses/tc101fall2015/wp-content/plugins/slickr-flickr/classes/class-plugin.php:152) in /home/kenbauer/public_kenscourses/tc101fall2015/wp-includes/rest-api/class-wp-rest-server.php on line 1831
{"id":24643,"date":"2015-10-28T03:39:00","date_gmt":"2015-10-28T09:39:00","guid":{"rendered":"http:\/\/kenscourses.com\/tc101fall2015\/?guid=9b8a751b291329ddcdcbeb00fb8ae597"},"modified":"2015-10-28T03:39:36","modified_gmt":"2015-10-28T09:39:36","slug":"recursion","status":"publish","type":"post","link":"https:\/\/kenscourses.com\/tc101fall2015\/2015\/recursion\/","title":{"rendered":"Recursion"},"content":{"rendered":"
       In some programs we need to get a result that consists on repeating the same algorithm certain amount of times. For obtaining the result we need to obtain the result of the same problem in smaller instances. <\/o:p><\/span><\/span><\/div>\n
<\/div>\n
For example:<\/b><\/o:p><\/span><\/span><\/div>\n
<\/div>\n
       We want to obtain the result of certain number raised to another number. This is the same as multiplying the first number by itself during the second number of times. <\/o:p><\/span><\/span><\/div>\n

<\/span><\/div>\n
<\/span><\/a><\/div>\n

<\/p>\n

<\/span><\/a><\/div>\n

<\/p>\n

      But also, this is the same as multiplying the first number times the first number raised to second number minus 1.<\/o:p><\/span><\/span><\/div>\n

<\/span><\/span><\/div>\n

<\/span><\/span><\/div>\n
For example:<\/b><\/o:p><\/span><\/span><\/div>\n
    <\/span> 5^3<\/span> is the same as:<\/o:p><\/span><\/span><\/div>\n
     <\/span>5*5*5<\/span><\/o:p><\/span><\/span><\/div>\n
     Which is the same as:<\/o:p><\/span><\/span><\/div>\n
     <\/span>5*5^2 <\/span>which is the same as: <\/span>5*5*5^1<\/span> which is the same as <\/span>5*5*5*5^1<\/span><\/o:p><\/span><\/span><\/div>\n
Now we just need to know what <\/span>5^1<\/span> is equal to.<\/o:p><\/span><\/span><\/div>\n

<\/span><\/span><\/div>\n
<\/div>\n

<\/p>\n

     What we just did is what we call recursion. We want to obtain the result of a problem by solving the same problem in smaller instances. It can be applied to code in this way:<\/o:p><\/span><\/span><\/div>\n


<\/span><\/p>\n

<\/span><\/a><\/div>\n

<\/span><\/div>\n
       And it gives us the same answer:<\/o:p><\/span><\/span><\/div>\n

<\/p>\n

<\/span><\/a><\/div>\n

<\/span><\/div>\n
       Another example is a number in the Fibonacci series. <\/o:p><\/span><\/span><\/div>\n

<\/span><\/span><\/div>\n
       This series start with the value \u201c<\/span>0<\/span>\u201d, followed by \u201c<\/span>1<\/span>\u201d. After that, every number is equal to the sum of the two previous numbers. This means that the third number will be equal to 0+1 which is 1. And the fourth number will be <\/span>1+1<\/span> which is <\/span>2.<\/span><\/o:p><\/span><\/span><\/div>\n

<\/span><\/span><\/div>\n
      This can be solved used recursion.<\/o:p><\/span><\/span><\/div>\n

<\/span><\/span><\/div>\n
      <\/span>If we get asked for the tenth number in the Fibonacci series, this will be the sum of the ninth and the eight numbers.<\/span><\/span><\/div>\n
     And the ninth number is the sum of the eight and the seventh.<\/span><\/div>\n
     The eight is the sum of the seventh and the sixth\u2026<\/span><\/div>\n
<\/div>\n
    And so on until we get to the first two number, that are the ones that we actually know.<\/span><\/o:p><\/span><\/span><\/div>\n
<\/div>\n
<\/span><\/a><\/div>\n

<\/p>\n

<\/span><\/a><\/div>\n

<\/span><\/div>\n
Here is the series so you can prove the answer is correct<\/o:p><\/span><\/span><\/div>\n
<\/div>\n
( 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89 )<\/span><\/o:p><\/span><\/span><\/div>\n
<\/div>\n","protected":false},"excerpt":{"rendered":"
       In some programs we need to get a result that consists on repeating the same algorithm certain amount of times. For obtaining the result we need to obtain the result of the same problem in smaller instances. <\/p>\n

<\/span><\/span><\/div>\n

<\/div>\n
For example:<\/b><\/p>\n

<\/span><\/span><\/div>\n

<\/div>\n
       We want to obtain the result of certain number raised to another number. This is the same as multiplying the first number by itself during the second number of times. <\/p>\n

<\/span><\/span><\/div>\n


<\/span><\/div>\n
<\/span><\/a><\/div>\n

<\/p>\n

<\/span><\/a><\/div>\n

<\/p>\n

      But also, this is the same as multiplying the first number times the first number raised to second number minus 1.<\/p>\n

<\/span><\/span><\/div>\n


<\/span><\/span><\/div>\n

<\/span><\/span><\/div>\n
For example:<\/b><\/p>\n

<\/span><\/span><\/div>\n

    <\/span> 5^3<\/span> is the same as:<\/p>\n

<\/span><\/span><\/div>\n

     <\/span>5*5*5<\/span><\/p>\n

<\/span><\/span><\/div>\n

     Which is the same as:<\/p>\n

<\/span><\/span><\/div>\n

     <\/span>5*5^2 <\/span>which is the same as: <\/span>5*5*5^1<\/span> which is the same as <\/span>5*5*5*5^1<\/span><\/p>\n

<\/span><\/span><\/div>\n

Now we just need to know what <\/span>5^1<\/span> is equal to.<\/p>\n

<\/span><\/span><\/div>\n


<\/span><\/span><\/div>\n
<\/div>\n

<\/p>\n

     What we just did is what we call recursion. We want to obtain the result of a problem by solving the same problem in smaller instances. It can be applied to code in this way:<\/p>\n

<\/span><\/span><\/div>\n


<\/span><\/p>\n

<\/span><\/a><\/div>\n

<\/span><\/div>\n
       And it gives us the same answer:<\/p>\n

<\/span><\/span><\/div>\n

<\/p>\n

<\/span><\/a><\/div>\n

<\/span><\/div>\n
       Another example is a number in the Fibonacci series. <\/p>\n

<\/span><\/span><\/div>\n


<\/span><\/span><\/div>\n
       This series start with the value “<\/span>0<\/span>”, followed by “<\/span>1<\/span>”. After that, every number is equal to the sum of the two previous numbers. This means that the third number will be equal to 0+1 which is 1. And the fourth number will be <\/span>1+1<\/span> which is <\/span>2.<\/span><\/p>\n

<\/span><\/span><\/div>\n


<\/span><\/span><\/div>\n
      This can be solved used recursion.<\/p>\n

<\/span><\/span><\/div>\n


<\/span><\/span><\/div>\n
      <\/span>If we get asked for the tenth number in the Fibonacci series, this will be the sum of the ninth and the eight numbers.<\/span><\/span><\/div>\n
     And the ninth number is the sum of the eight and the seventh.<\/span><\/div>\n
     The eight is the sum of the seventh and the sixth…<\/span><\/div>\n
<\/div>\n
    And so on until we get to the first two number, that are the ones that we actually know.<\/span><\/p>\n

<\/span><\/span><\/div>\n

<\/div>\n
\"Recursion\"<\/span><\/a><\/div>\n

<\/p>\n

<\/span><\/a><\/div>\n

<\/span><\/div>\n
Here is the series so you can prove the answer is correct<\/p>\n

<\/span><\/span><\/div>\n

<\/div>\n
( 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89 )<\/span><\/p>\n

<\/span><\/span><\/div>\n

<\/div>\n","protected":false},"author":296,"featured_media":24642,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4,3],"tags":[335],"_links":{"self":[{"href":"https:\/\/kenscourses.com\/tc101fall2015\/wp-json\/wp\/v2\/posts\/24643"}],"collection":[{"href":"https:\/\/kenscourses.com\/tc101fall2015\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/kenscourses.com\/tc101fall2015\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/kenscourses.com\/tc101fall2015\/wp-json\/wp\/v2\/users\/296"}],"replies":[{"embeddable":true,"href":"https:\/\/kenscourses.com\/tc101fall2015\/wp-json\/wp\/v2\/comments?post=24643"}],"version-history":[{"count":1,"href":"https:\/\/kenscourses.com\/tc101fall2015\/wp-json\/wp\/v2\/posts\/24643\/revisions"}],"predecessor-version":[{"id":24644,"href":"https:\/\/kenscourses.com\/tc101fall2015\/wp-json\/wp\/v2\/posts\/24643\/revisions\/24644"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/kenscourses.com\/tc101fall2015\/wp-json\/wp\/v2\/media\/24642"}],"wp:attachment":[{"href":"https:\/\/kenscourses.com\/tc101fall2015\/wp-json\/wp\/v2\/media?parent=24643"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/kenscourses.com\/tc101fall2015\/wp-json\/wp\/v2\/categories?post=24643"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/kenscourses.com\/tc101fall2015\/wp-json\/wp\/v2\/tags?post=24643"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}