SOLUTION: if N is divided by 7 the remainder is 4 and if same number N is divided by 8 the remainder is 2. what is the value of N?

Algebra ->  Coordinate Systems and Linear Equations  -> Linear Equations and Systems Word Problems -> SOLUTION: if N is divided by 7 the remainder is 4 and if same number N is divided by 8 the remainder is 2. what is the value of N?      Log On


   



Question 770086: if N is divided by 7 the remainder is 4 and if same number N is divided by 8 the remainder is 2. what is the value of N?
Found 2 solutions by ramkikk66, KMST:
Answer by ramkikk66(644) About Me  (Show Source):
You can put this solution on YOUR website!
if N is divided by 7 the remainder is 4 and if same number N is divided by 8 the remainder is 2. what is the value of N?
Ans:
N divided by 7 gives remainder 4. So N can be written as 7*m + 4 for some integer m.
N divided by 8 gives remainder 2. So N can be written as 8*n + 2 for some integer n.
Equating the 2 expressions for N
7*m + 4 = 8*n + 2
7*m + 2 = 8*n
Need to find which integer values of m and n satisfy the above equation. Since it
is only 1 equation with 2 unknown variables m and n, we can do it only by trial
and error. Try different values for m (1,2,3..) and see if we get an integer 
value for n.
We see that one possible solution is m = 2, n = 2
7*2 + 2 = 8*2
So the number N is 7*m + 4 = 18.
Check: 18 div by 7 gives remainder 4, 18 div by 8 gives remainder 2 :)
There are other solutions too - e.g. 74 also gives 4 as remainder when divided
by 7 and a remainder of 2 when divided by 8. But 18 is the smallest such number.
:)


Answer by KMST(5328) About Me  (Show Source):
You can put this solution on YOUR website!
From 7%2Am+%2B+2+=+8%2An you get
7m%2B2=%287%2B1%29n%2B4-->7m%2B2=7n%2Bn-->7m-7n%2B2=n-->n=7%28m-n%29%2B2
%28m-n%29%3C=-1 would yield a negative n,
n%3C=-5 and a negative N,
N=8n%2B4%3C=-20%2B4=-16 and that does not make sense.
%28m-n%29 could be 0, 1, 2, 3, ...
For m-n=0 we get n=7%2A0%2B2-->n=2-->N=8%2A2%2B2-->highlight%28N=18%29
But there is an infinite number of other solutions.
m-n=1 yields n=7%2A1%2B2-->n=9-->N=8%2A9%2B2-->highlight%28N=74%29
m-n=2 yields n=7%2A2%2B2-->n=16-->N=8%2A16%2B2-->highlight%28N=130%29
and so on.
After finding n=18 as one solution, we can keep getting more solutions n by adding 56=7%2A8 each time.
Since 56 has a remainder of 0 when divided by either 7 or 8, adding 56 or a multiple of 56 does not change the remainders.
In general, we could rename m-n as p and say that p is a non-negative integer.
Then n=7p%2B2 and N=8%287p%2B2%29%2B2-->N=56p%2B16%2B2-->highlight%28N=56p%2B18%29