English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

pick a number between 3 and 100, divide the number over 3,5 and 7 seperately, from the three reminders you should be able to give the earlier picked number.

ex.

if we picked 26
26/3 = 8 with 2 remaining
26/5 = 5 with 1 remianing
26/7 = 3 with 5 remianing

if the numbers 2,1 and 5 are given as reminders for 3,5 and 7 respectivly, is there a systematic way, formula to find the picked number (26 in this example) i have a solution but i couldnt put it in a mathimatical shape, so i will post it if i didnt get a solution !

2006-11-12 09:09:13 · 3 answers · asked by Ahmad 2 in Science & Mathematics Mathematics

iam not sure i got an answer yet!
if gauger_1 answer was true
(X = (1 * 21) + (5 * 15) - (2 * 35))
then if we picked 55,

R1 = 1
R2 = 0
R3 = 6

x = 21 + 0 - 210 = -189

for Roman Soldier,

i am not a programmer, but i think a program should be based ona mathemetical model! so if it fails the program will fail as well!

2006-11-13 06:59:15 · update #1

3 answers

If x = original number
and
R1= remainder of x/3
R2= remainder of x/5
R3= remainder of x/7

Then x = (R2 * 21) + (R3 * 15) - (R1 * 35)

So for your example of 26:
R1 = 2
R2 = 1
R3 = 5

X = (1 * 21) + (5 * 15) - (2 * 35)
= 21 + 75 - 70
= 26

Notice how the remainder of one number relates to the multiple of the other two. Also, I think you need to start at 7 instead of 3, because there will be fractions and no remainders for the numbers less than 7.

EDIT:

If you look at the formula again, you will see that it works for your example, also! =)

Be careful where you plug in your numbers; they aren't in order.

2006-11-12 10:35:05 · answer #1 · answered by gauger_1 3 · 0 0

Well in computer programming you use the modulus "%" to find a remainder. The 3 gives the tens place so we multiply remainder by 10. So the equation would look something like this:

N will be our number.

10*(N%3) + N%5 + N%7 = N

EDIT:
I ran this through a simple java program and you don't get the same number for every thing. 25 for example will spit out 14. 26 works, and might a few others.

2006-11-12 09:20:14 · answer #2 · answered by Roman Soldier 5 · 0 1

Start with the remainder from seven and continue to add seven all the way up to a hundred. Then do the same with five and three eliminating all numbers that aren't a part of all three groups. This should help.

2006-11-12 09:20:37 · answer #3 · answered by dkrusekontrol 2 · 0 1

fedest.com, questions and answers