#### Re: Cool problem

Hello, bzig, you wrote: B> Cool problem B> B> two brothers had a herd of rams. They sold it and for each ram received so much roubles, how many goals were in herd. A gain began to halve. To the Big brother - to ten, the younger brother - to ten, high - to ten, low - to ten. And so some times. Then the big brother took the ten, and low several roubles did not suffice to ten. Then the senior took out a knife from a pocket and gave to the brother to compensating for the missing total. A question: the knife How many cost? However it turns out that the task has the decision at an amount of rams N=5*k - + 1. We receive that does not suffice 4-re a coin, hence the knife costs 2. A cool problem. Thanks. Deduce the mathematical proof to unwinding I can not, I will make later. Or I will look here.

#### Re: Cool problem

Hello, biochemist, you wrote: B> Deduce the mathematical proof to unwinding I can not, I will make later. Or I will look here. The n-number of rams r-how many should be added the s-rest n^2=20*k+10+s = 20*k+20-r n=10*a + b b = [0. 9] r = [1. 9] 100*a^2 + 20*a*b + b^2 = 20 * (k+1) - r %20 0 + 0 + b^2 = 20 - r %20 b b^2%20 r--------------- 0 0 0 - 1 1 19 - 2 4 16 - 3 9 11 - 4 16 4 + 5 5 15 - 6 16 4 + 7 9 11 - 8 4 16 - 9 1 19 - variants b = [4,6] approach only at them r=4. The knife costs half r.

#### Re: Cool problem

Hello, bzig, you wrote: B> B> two brothers had a herd of rams. They sold it and for each ram received so much roubles, how many goals were in herd. A gain began to halve. To the Big brother - to ten, the younger brother - to ten, high - to ten, low - to ten. And so some times. Then the big brother took the ten, and low several roubles did not suffice to ten. Then the senior took out a knife from a pocket and gave to the brother to compensating for the missing total. A question: the knife How many cost? Let N - an amount of rams, Z - residual from ten. div - integer division operation. (N div 10) = 2x + 1 (N * N) - ((N div 10) * 10) = Z we designate N * N = Y Y = 10 * (2x + 1) + Z from a statement of the problem z belongs to an interval [1. . 9] as Y = 10 * _ + z from here we receive that the last digit Y is equal Z as Y simultaneously is square N its last digit (so and Z) can be only 0, 1, 4, 5, 6 or 9 0 on a statement of the problem does not approach, means Z can be 1, 4, 5, 6 or 9 further, under formula Y represents an infinite series with step 20 and unknown digit in the end: 10+Z, 30+Z, 50+Z, 70+Z, 90+Z, 110+Z, 130+Z... In this row penultimate digit always odd From article in Wikipedia we learn that that the penultimate digit of our row was odd, last can be only "6": https://ru.wikipedia.org/wiki/%D0%9F%D0 … 0%B2%D0%B0 that is Z = 6, and knife cost - 4 it is finite, the proof not absolutely strict, well here to a head came Upd. And, in the help in a hidden text did not look, all fairly tried to solve itself

#### Re: Cool problem

B> However it turns out that the task has the decision at an amount of rams N=5*k - + 1. We receive that does not suffice 4-re a coin, hence the knife costs 2. It also with a double bottom, appears. I only to 4 reached

#### Re: Cool problem

Hello, biochemist, you wrote: B>> B>> two brothers had a herd of rams. They sold it and for each ram received so much roubles, how many goals were in herd. A gain began to halve. To the Big brother - to ten, the younger brother - to ten, high - to ten, low - to ten. And so some times. Then the big brother took the ten, and low several roubles did not suffice to ten. Then the senior took out a knife from a pocket and gave to the brother to compensating for the missing total. A question: the knife How many cost? B> however it turns out that the task has the decision at an amount of rams N=5*k - + 1. We receive that does not suffice 4-re a coin, hence the knife costs 2. Here did not understand - "N=5*k - + 1" - here plus or a minus? If to take =2 will be either 121 ram, or 81 - any of these variants does not approach. Or I do not understand something?

#### Re: Cool problem

Hello, AlexRK, you wrote: ARK> Here did not understand - "N=5*k - + 1" - here plus or a minus? If to take =2 will be either 121 ram, or 81 - any of these variants does not approach. Or I do not understand something? Yes. I already understood that answered not correctly. Right answer Kov_Serg the Author: kov_serg Date: 16.11 11:04.