Background

creative commons licensed (BY-NC-SA) flickr photo by the past tends to disappear: http://flickr.com/photos/daniandgeorge/11906109865

creative commons licensed (BY-NC-SA) flickr photo by the past tends to disappear: http://flickr.com/photos/daniandgeorge/11906109865

In this assignment you will write a function to calculate the greatest common denominator of two positive integers using Euclid’s algorithm.

What to Do

The function should receive two integers and return an integer.Obviously you should test your function, so create a main program that asks the user for two values, calculates the gcd and displays that.

What to Submit

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 #WSQ12 on your post so our blog hub picks that up.

You should include your code as a link to GitHub.

And of course, leave any questions here as well as asking those questions on Twitter with the hashtag #TC1014 so we all see your question posted there.

CC BY 4.0 WSQ12 – Greatest Common Divisor by Ken Bauer is licensed under a Creative Commons Attribution 4.0 International License.