{"id":38499,"date":"2016-05-14T11:19:40","date_gmt":"2016-05-14T16:19:40","guid":{"rendered":"http:\/\/lilihecblog.wordpress.com\/?p=178"},"modified":"2016-05-15T07:33:21","modified_gmt":"2016-05-15T12:33:21","slug":"quiz-6-19","status":"publish","type":"post","link":"https:\/\/kenscourses.com\/tc101winter2016\/2016\/05\/quiz-6-19\/","title":{"rendered":"QUIZ 6"},"content":{"rendered":"<p>Este programa escribe una funci\u00f3n para calcular el m\u00e1ximo com\u00fan denominador de dos n\u00fameros positivos;<\/p>\n<p>\/\/CODE:<\/p>\n<p>#include &lt;iostream&gt;<br \/>\nusing namespace std;<\/p>\n<p>int gcd(int x, int y){<br \/>\nint r;<br \/>\nif (x==0){<br \/>\nreturn x;<br \/>\n}<br \/>\nwhile (y!=0){<br \/>\nr= y;<br \/>\ny= x%y;<br \/>\nx= r;<br \/>\n}<br \/>\nreturn r;<br \/>\n}<\/p>\n<p>int main (){<br \/>\nint x,y;<br \/>\ncout&lt;&lt;\u201cPlease enter a number: \u201d &lt;&lt;endl;<br \/>\ncin&gt;&gt;x;<br \/>\ncout&lt;&lt;\u201cPlease enter a second number: \u201d &lt;&lt;endl;<br \/>\ncin&gt;&gt;y;<br \/>\ncout&lt;&lt;\u201cThe greatest common denominator between (\u201d &lt;&lt;x &lt;&lt;\u201d y \u201d &lt;&lt;y &lt;&lt;\u201c) is = \u201d &lt;&lt; gcd(x,y) &lt;&lt;endl;<\/p>\n<p>return 0;<br \/>\n}<\/p>\n<p><img decoding=\"async\" class=\"alignnone size-full wp-image-181\" src=\"http:\/\/kenscourses.com\/tc101winter2016\/wp-content\/uploads\/2016\/05\/b557e76f3b4fe9ffab77d1e29ddd9d11.jpg\" alt=\"Captura de pantalla 2016-05-14 a las 11.19.21.png\"   \/><\/p>\n<p>  <a rel=\"nofollow\" href=\"http:\/\/feeds.wordpress.com\/1.0\/gocomments\/lilihecblog.wordpress.com\/178\/\"><img decoding=\"async\" alt=\"\" border=\"0\" src=\"http:\/\/kenscourses.com\/tc101winter2016\/wp-content\/uploads\/2016\/05\/d9ec07af7766dfde1e8b7fbc79c0ce13.jpg\" \/><\/a> <img loading=\"lazy\" decoding=\"async\" alt=\"\" border=\"0\" src=\"http:\/\/kenscourses.com\/tc101winter2016\/wp-content\/uploads\/2016\/05\/573949f63ca03695149774f603b8a23b.jpg#038;blog=105581831&#038;%23038;post=178&#038;%23038;subd=lilihecblog&#038;%23038;ref=&#038;%23038;feed=1\" width=\"1\" height=\"1\" \/><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Este programa escribe una funci\u00f3n para calcular el m\u00e1ximo com\u00fan denominador de dos n\u00fameros positivos; \/\/CODE: #include &lt;iostream&gt; using namespace std; int gcd(int x, int y){ int r; if (x==0){ return x; } while (y!=0){ r= y; y= x%y; x= r; } return r; } int main (){ int x,y; cout&lt;&lt;\u201cPlease enter a number: \u201d &hellip; <a href=\"https:\/\/kenscourses.com\/tc101winter2016\/2016\/05\/quiz-6-19\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">QUIZ 6<\/span><\/a><\/p>\n","protected":false},"author":77,"featured_media":38524,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5,4],"tags":[45],"class_list":["post-38499","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-blogs","category-syndicated","tag-sin-categoria"],"_links":{"self":[{"href":"https:\/\/kenscourses.com\/tc101winter2016\/wp-json\/wp\/v2\/posts\/38499","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\/77"}],"replies":[{"embeddable":true,"href":"https:\/\/kenscourses.com\/tc101winter2016\/wp-json\/wp\/v2\/comments?post=38499"}],"version-history":[{"count":2,"href":"https:\/\/kenscourses.com\/tc101winter2016\/wp-json\/wp\/v2\/posts\/38499\/revisions"}],"predecessor-version":[{"id":38528,"href":"https:\/\/kenscourses.com\/tc101winter2016\/wp-json\/wp\/v2\/posts\/38499\/revisions\/38528"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/kenscourses.com\/tc101winter2016\/wp-json\/wp\/v2\/media\/38524"}],"wp:attachment":[{"href":"https:\/\/kenscourses.com\/tc101winter2016\/wp-json\/wp\/v2\/media?parent=38499"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/kenscourses.com\/tc101winter2016\/wp-json\/wp\/v2\/categories?post=38499"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/kenscourses.com\/tc101winter2016\/wp-json\/wp\/v2\/tags?post=38499"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}