Awesome q2a theme
0 votes
41 views
$\gcd(36,k)=6$, then what is the k?

I know the only naive method,can anyone explain any other method.
in Numerical Ability by (116 points)
edited by | 41 views

1 Answer

0 votes
Why naive method?

Its straight forward that gcd is 6, that means whatever be the number that must the product of 2 smallest primes. Hence 6 is clearly the answer

But if you keep on increasing the multiple of 6 then you won’t get GCD as 6, then GCD would get mulitplied by 2 and 3
by (356 points)
0
I know the method like this

$36=2 \times {\color{Red}{2 \times 3} } \times 3 $

$6={\color{Red}{2 \times 3 } }$

Less than can’t be possible and multiple of $’6’$  which is less than or equal to $’36’$  is also not possible because $36$ is a multiple of $6$.

So, $k=6,42$ is possible.
0
int gcd(int a, int b)
{

    if  (a == 0)
       return b;
    if (b == 0)
       return a;
   
    if (a == b)
        return a;
   
    if (a > b)
        return gcd(a-b, b);
    return gcd
}

Here we can put 36 and 6 as two elements $a$ and $b$. It will give the other number

+2
K can be 42 also :(
0
Yes, you are right, I missed that one.

any other possibilities are there?
+2
36*i+ 6 for all i > 0
0
Can be write $i\geq 0?$
0
if $\gcd (48,k) = 6$

then $k=48\times i + 6\:\:\forall i \geq 0$

it is right?
Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true
Welcome to GATE CSE Doubts, where you can ask questions and receive answers from other members of the community.
Top Users May 2020
  1. Kushagra गुप्ता

    97 Points

  2. praveen modala

    15 Points

  3. ramcharantej_24

    15 Points

  4. abhishek tiwary

    12 Points

  5. srestha

    12 Points

  6. Dtiwari

    9 Points

  7. Shivateja MST

    8 Points

  8. ankitgupta.1729

    8 Points

  9. Rashimdixit

    7 Points

  10. Bhavya1902

    7 Points

7,376 questions
1,741 answers
10,682 comments
90,352 users