Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9072561
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T18:11:52+00:00 2026-06-16T18:11:52+00:00

The following provides a pre and post condition for the gcd method. pre: x

  • 0

The following provides a pre and post condition for the gcd method.

pre: x > 0 & y > 0 
post: result > 0 &
      x mod result = 0 & y mod result = 0 &
      ∀t:Integer · t > 0 & x mod t = 0 & y mod t = 0 ⇒ result mod t = 0

However, I’m having trouble following the post condition… to me it basically says find any integer that is divisible by both. How does it get the maximum divisor, what are the conditions actually saying?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T18:11:54+00:00Added an answer on June 16, 2026 at 6:11 pm

    This one assures that result is the greatest of all common divisors.

    ∀t:Integer·t>0 & x mod t=0 & y mod t = 0 ⇒ result mod t = 0
    

    It says that any t, which is a common divisor of x and y, is also a divisor of result

    EDIT: you should read the above line like this:

    ∀t:Integer·((t>0 & x mod t=0 & y mod t = 0) ⇒ result mod t = 0)
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Backbone.js provides a navigate(fragment, [options]) method for its Backbone.router objects, which does the following
The Wikipedia article on the Y combinator provides the following JavaScript implementation of the
The permission/authentication documentation for Django 1.4 provides the following snippet for creating custom permissions
The Roku media player provides a RESTful API with the following commands: query/apps This
The following feature needs to be implemented to our existing QT & C++ application.
I am using package qvalue which has the following pre-processing step if(min(p)<0 || max(p)>1)
The following TSQL provides an example of how I might solve this problem with
I'm using the following T4 template ( http://blogs.msdn.com/b/adonet/archive/2008/06/20/how-to-use-a-t4-template-for-view-generation.aspx ) to pre-compile my Entity Framework
I've got the following JSON provided from a server. With this, I want to
Provided the following ruby hash: { cat: { 1: 2, 2: 10, 3: 11,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.