{"id":34230,"date":"2016-03-21T12:12:14","date_gmt":"2016-03-21T18:12:14","guid":{"rendered":"http:\/\/bosonprogrammer.wordpress.com\/?p=480"},"modified":"2016-03-21T13:10:32","modified_gmt":"2016-03-21T19:10:32","slug":"euclids-on-the-block-quiz6","status":"publish","type":"post","link":"https:\/\/kenscourses.com\/tc101winter2016\/2016\/03\/euclids-on-the-block-quiz6\/","title":{"rendered":"Euclids on the block! #Quiz6"},"content":{"rendered":"<p>Euclides es como mi dignidad, yo aseguro que existe pero nadie est\u00e1 de acuerdo con eso. Al igual que lo anterior dicho, la ente simplemente no puede ponerse de acuerdo sobre si Euclides existi\u00f3 o no, lo que no se puede negar ni de broma, es la utilidad de su algoritmo es la geometr\u00eda.<\/p>\n<div data-shortcode=\"caption\" id=\"attachment_485\" style=\"width: 607px\" class=\"wp-caption aligncenter\"><img decoding=\"async\" class=\"aligncenter size-full wp-image-485\" src=\"http:\/\/kenscourses.com\/tc101winter2016\/wp-content\/uploads\/2016\/03\/9468d2debc1dfe8332436d37a1206275.jpg\" alt=\"Euclid_o_24537\"   \/><\/p>\n<p class=\"wp-caption-text\">Esta es la mejor imagen que pude encontrar.<\/p>\n<\/div>\n<p>El c\u00f3digo result\u00f3 ser muy sencillo, creo que ha sido el m\u00e1s corto de todos pues la salida del programa s\u00f3lo ten\u00eda que ser el MCD (m\u00e1ximo com\u00fan divisor) y la funci\u00f3n principal era portar el algoritmo de Euclides hacia el lenguaje de programaci\u00f3n, el cual result\u00f3 en esto:<\/p>\n<pre class=\"brush: python; title: ; notranslate\">\n# --------------------- Este es el c\u00f3digo correspondiente al Quiz 6 ----------------------------\ndef ade(a, b):\nif a &gt; b:\nc = a - b\nade(b, c)\nelif a &lt; b:\nc = b - a\nade(a, c)\nelse:\nprint(a)\n\nade(a=int(input(&quot;Vamos, introduce el primer n\u00famero: &quot;)), b=int(input(&quot;Ahora introduce el segundo n\u00famero: &quot;)))\n\n<\/pre>\n<p>Como siempre, mi c\u00f3digo en <a href=\"https:\/\/github.com\/jjnorris31\/-TC101\/blob\/master\/%23Quiz6\">Github<\/a> est\u00e1 aqu\u00ed.<\/p>\n<p>&nbsp;<\/p>\n<p>  <a rel=\"nofollow\" href=\"http:\/\/feeds.wordpress.com\/1.0\/gocomments\/bosonprogrammer.wordpress.com\/480\/\"><img decoding=\"async\" alt=\"\" border=\"0\" src=\"http:\/\/kenscourses.com\/tc101winter2016\/wp-content\/uploads\/2016\/03\/3f680749c7c5fb545fc4425f02689a7e-1.jpg\" \/><\/a> <img loading=\"lazy\" decoding=\"async\" alt=\"\" border=\"0\" src=\"http:\/\/kenscourses.com\/tc101winter2016\/wp-content\/uploads\/2016\/03\/e57076b0bcad53777410520c87383f22.jpg#038;blog=105753380&#038;%23038;post=480&#038;%23038;subd=bosonprogrammer&#038;%23038;ref=&#038;%23038;feed=1\" width=\"1\" height=\"1\" \/><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Euclides es como mi dignidad, yo aseguro que existe pero nadie est\u00e1 de acuerdo con eso. Al igual que lo anterior dicho, la ente simplemente no puede ponerse de acuerdo sobre si Euclides existi\u00f3 o no, lo que no se puede negar ni de broma, es la utilidad de su algoritmo es la geometr\u00eda. Esta &hellip; <a href=\"https:\/\/kenscourses.com\/tc101winter2016\/2016\/03\/euclids-on-the-block-quiz6\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">Euclids on the block! #Quiz6<\/span><\/a><\/p>\n","protected":false},"author":72,"featured_media":34231,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5,4],"tags":[31,166,162,56,223,182],"class_list":["post-34230","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-blogs","category-syndicated","tag-tc101","tag-codigo","tag-funciones","tag-python","tag-quiz6","tag-quizes"],"_links":{"self":[{"href":"https:\/\/kenscourses.com\/tc101winter2016\/wp-json\/wp\/v2\/posts\/34230","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/kenscourses.com\/tc101winter2016\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/kenscourses.com\/tc101winter2016\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/kenscourses.com\/tc101winter2016\/wp-json\/wp\/v2\/users\/72"}],"replies":[{"embeddable":true,"href":"https:\/\/kenscourses.com\/tc101winter2016\/wp-json\/wp\/v2\/comments?post=34230"}],"version-history":[{"count":3,"href":"https:\/\/kenscourses.com\/tc101winter2016\/wp-json\/wp\/v2\/posts\/34230\/revisions"}],"predecessor-version":[{"id":34238,"href":"https:\/\/kenscourses.com\/tc101winter2016\/wp-json\/wp\/v2\/posts\/34230\/revisions\/34238"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/kenscourses.com\/tc101winter2016\/wp-json\/wp\/v2\/media\/34231"}],"wp:attachment":[{"href":"https:\/\/kenscourses.com\/tc101winter2016\/wp-json\/wp\/v2\/media?parent=34230"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/kenscourses.com\/tc101winter2016\/wp-json\/wp\/v2\/categories?post=34230"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/kenscourses.com\/tc101winter2016\/wp-json\/wp\/v2\/tags?post=34230"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}