Please answer the extra credit portion only: 2. spy+spy: Two spies, A and B, eac
ID: 2967223 • Letter: P
Question
Please answer the extra credit portion only:
2. spy+spy: Two spies, A and B, each have a secret number in [1..m). To exchange numbers they agree to meet at the river and ''innocently'' take turns throwing stones: from a pile of n identical stones, each spy in turn throws at least one stone in the river. The only information is in the number of stones each thrown in each turn. They would like to know the largest m can be, as a function of n, so they can be sure to complete the exchange. (b) Extra Credit: write a recursive definition of the function R(m, n), which returns the top of the range [1..R(m, n)) that A can send to B if there are n stones left, and A still needs to receive a number from [1..m) from B. (Note: R(1, n)= Fn, R(2,-) begins 0,0,0,1,2,4,7,12; R(3, -) begins 0,0,0,0,1,2,4,8,15,27. There will not be a nice closed form for these numbers.)Explanation / Answer
not sure....just trying how this works