2013年11月14日星期四

Nov.14th New puzzle comes!


Yesterday we had term test two, which counts 6% of total. For me the Racket questions were fairly easy but I found the first two short answer questions really really challenging. The first one, asking about whether it is essential for government support on the creation of internet, sounds very “stupid” to me (well I mean I got stupid when seeing this question). I ended up using the common sense in the last couple of minutes because I just could not relate it to lecture materials. By contrast, the second one was so specific. My brain was stuck when learning about the internet and that’s exactly what Danny asked about... Good shoot...

Before the test, we still had a two-hour lecture as usual. This time we talked about some social issues such as how many hours of work do we prefer to have every week. It might sound illogical that although modern computers and machines have been used to replace the majority of human work, we still end up working for longer hours and also harder than the past generations. One possible answer I could come up with is that we are now opening a broader and broader market on production and consumption so that far more works are required  than ever before. 

Anyway, what I really want to talk about is the new puzzle problem: the biggest possible product of a series of numbers that have the same sum. For example, the list of positive integers that add up to 1 is (1), and the product of this list (if you allow unary products) is also 1.There are two lists of positive integers that add up to 2, and they yield two different products: (2) (with product 2), and (1,1) (with product 1). There are several lists of positive integers that add up to 3, and they yield several different products: (3) (with product 3), (2,1) (with product 2), and (1,1,1) (with product 1). And the puzzle is: If n is a positive integer, what is the maximum product that can be formed of a list of positive integers that sum to n?

Intuitively, I think working out this question needs the previous knowledge on recursion, but I can not think of a solution immediately. Also, a good way to get further is to try some small numbers, after which I got the idea that the biggest product is made up of threes or all three but one or two twos. Maybe we can split it into five conditions(n=1, n=2, n=3, n=4, n>4) but again, I fail to get the entire, logical solution. Nor can I suggest a clear way to work this out. As we have learned well before, there are mainly four stages of solving a problem: Understand the problem, devise a plan or two, carry out the best plan, and lastly look back to verify or seek for breakthrough, It seems that I’m half way to the second stage.

Love puzzles anyways. To be continued...

2 条评论:

  1. Keep trying small numbers, let's say n < 10, to see whether you see any pattern.

    回复删除
    回复
    1. Yep... I think the pattern is that the more threes, the better (but not leave a one. ie. if it is 3*3*3*3*1, then the biggest production should be 3*3*3*(3+1)). This might be enough to write a program, but I haven't come up with the proof :(

      删除