InterviewSolution
Saved Bookmarks
| 1. |
find q and r for the following pairs of positive integers a and b satisfying` a = bq+r``(1)a =13 , b=13 ``(2)a=8 , b=20``(3)a=125 , b=5``(4)a=132 ,b=11` |
|
Answer» given that, ` a= b*q +r ` in option 1 , given that `a= 13, b=13 ` `13= 13*q + r` `13*(1-q) = r` `if q= 0, r= -13` `if q=1, r= 0` `if q= 2 , r=-13` not possible `:.` 2 solutions can be possible. for option 2. given that `a= 8 , b=20` `8= 20*q+ r` `4(2-5*q)= r` `if q= 0 . r=8` `if q=1, r=-12 ` not possible so. 1 solution is possible. `a= 125 & b= 5` `125 = 5*q + r` `5*(25-q) = r` `if q=0, r=125` `if q=1, r=24*5` `if q=2, r= 23*5` `..` `..` `..` `..` `if q=25, r= 0` `if q= 26 , r=-ve` so, 25 solutions are possible.`a= 132, b=11` `132= 11*q + r` `132 - 11*q = r` `11*(12- q) = r` `q= 0 , r= 12*11` `q=1 , r= 11*11` `q=2 , r = 10*11` `..` `..` `q=12, r=0` `q= 13 , r= -ve` so, 12 solutions are possible. |
|