Jump to content
BrainDen.com - Brain Teasers
  • 0


superprismatic
 Share

Question

Consider the following array of numbers:


8 0 -4 -7 5 5 -11 11
14 -11 3 9 -4 -13 14 1
2 1 7 -6 14 -3 -3 3
12 -10 -14 12 -11 10 -4 -4
-13 -11 8 -12 1 14 3 -12
-1 -3 2 2 4 -10 -8 -5
-9 2 11 11 -10 5 -10 -12
[/code] Your task is to pick elements out of this array so that the sum of the elements you pick is as large as possible. You may pick the same element multiple times as long as you don't violate any of the following rules. Also, in the following, "between" is always inclusive. OVERALL RULE: You must choose precisely 100 elements out of the array. ROW RULES: You must choose between 4 and 30 elements from the first row, between 7 and 39 from the second row, between 8 and 20 from the third, between 6 and 22 from the fourth, between 7 and 35 from the fifth, between 4 and 29 from the sixth, and between 2 and 47 from the seventh. COLUMN RULES: You must choose between 1 and 31 from the first column, between 3 and 42 from the second, between 7 and 36 from the third, between 7 and 40 from the fourth, between 5 and 30 from the fifth, between 1 and 34 from the sixth, between 1 and 9 from the seventh, and between 3 and 38 from the eight. INDIVIDUAL ELEMENT RULES: In the following array, the element [A,B] in the i[sup]th[/sup] row and j[sup]th[/sup] column specifies that you must choose the element located in the i[sup]th[/sup] row and j[sup]th[/sup] column of the original array between A and B times.
[code]
[0,11] [0, 9] [0, 4] [2, 9] [2, 4] [2,12] [1, 9] [1, 4]
[1, 8] [0, 2] [0, 9] [1, 3] [1,13] [2, 9] [0, 8] [1, 7]
[0,12] [1,13] [2,14] [1, 9] [0, 0] [2,14] [2, 8] [1, 1]
[1, 8] [1, 7] [2, 3] [0,12] [1, 8] [0,14] [1, 2] [1,13]
[0, 4] [1, 3] [2,12] [1, 3] [1, 8] [1,11] [0, 2] [2, 4]
[1, 8] [0,11] [1, 2] [0, 5] [0, 6] [0, 1] [1,14] [1,10]
[2, 3] [0,11] [0,12] [0,10] [1,13] [2, 6] [0, 3] [0, 7]

So, for example, the -7 in the first

row of the original array must be chosen at

least twice but no more than 9 times.

I have checked several times that it is possible to

make choices which follow all the rules. I have a

putative best answer. See how large your sum of

100 elements can be while following all the rules.

I'll let you know if you get close (or surpass) my

best answer.

Link to comment
Share on other sites

16 answers to this question

Recommended Posts

  • 0

I don't know if I am close but

468


   0      0      0    -14     10     10    -11     11  =    6

 112      0      0      9     -4    -26     56      1  =  148

   0      1     14     -6      0     -6     -6      3  =    0

  12    -10    -28    144    -11      0     -4     -4  =   99

   0    -11     16    -12      1    154      0    -24  =  124

  -1      0      2      0      0      0     -8     -5  =  -12

 -18      0    121      0    -10     10      0      0  =  103

Edited by stewdeker
Link to comment
Share on other sites

  • 0

I don't know if I am close but

468


0 0 0 -14 10 10 -11 11 = 6
112 0 0 9 -4 -26 56 1 = 148
0 1 14 -6 0 -6 -6 3 = 0
12 -10 -28 144 -11 0 -4 -4 = 99
0 -11 16 -12 1 154 0 -24 = 124
-1 0 2 0 0 0 -8 -5 = -12
-18 0 121 0 -10 10 0 0 = 103

You're in the ballpark but still lower than mine. Nice going, especially since you've done it so quickly!

Link to comment
Share on other sites

  • 0

Ok I found a few more.

475


   0      0      0    -14     10     10    -11     11  =    6

 112      0      0      9     -4    -26     56      1  =  148 

   0      1     14     -6      0     -6     -6      3  =    0

  96    -10    -28    144    -11      0     -4     -4  =  183 *

   0    -11     16    -12      1    154      0    -24  =  124

  -1      0      2      0      0      0     -8     -5  =  -12

 -18      0     44      0    -10     10      0      0  =   26 *

*changed rows

Link to comment
Share on other sites

  • 0

You're in the ballpark but still lower than mine. Nice going, especially since you've done it so quickly!

Here's a try

Matrix of which element, and how many, to pick


     [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8]

[1,]    0    0    0    2    2    2    1    4

[2,]    8    0    0    1    1    2    4    1

[3,]    0    1    2    1    0    2    2    1

[4,]    4    1    2   12    1    0    1    1

[5,]    0    1    2    1    1   11    0    2

[6,]    1    0    1    0    0    0    1    1

[7,]    0    0    6   10    1    2    0    0

Row sum of the matrix

11 17 9 22 18 4 19

Column sum of the matrix

13 3 13 27 6 19 9 10

Total points = 610

Link to comment
Share on other sites

  • 0

Final answer:

I reworked the whole thing from the begining and

585


    0      0      0    -14     10     10    -11     44  =  39

  112      0      0      9     -4    -26     56      1  = 148

    0      1     14     -6      0     -6     -6      3  =   0

   96    -10    -28    144    -11      0     -4     -4  = 183

    0    -11     16    -12      1    154      0    -24  = 124

   -1      0      2      0      0      0     -8     -5  = -12

  -18      0     11    110    -10     10      0      0  = 103

Edited by stewdeker
Link to comment
Share on other sites

  • 0

Here's a try

Matrix of which element, and how many, to pick


     [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8]

[1,]    0    0    0    2    2    2    1    4

[2,]    8    0    0    1    1    2    4    1

[3,]    0    1    2    1    0    2    2    1

[4,]    4    1    2   12    1    0    1    1

[5,]    0    1    2    1    1   11    0    2

[6,]    1    0    1    0    0    0    1    1

[7,]    0    0    6   10    1    2    0    0

Row sum of the matrix

11 17 9 22 18 4 19

Column sum of the matrix

13 3 13 27 6 19 9 10

Total points = 610

In row 7 col 1 you have 0 when the min is 2

Link to comment
Share on other sites

  • 0

In row 7 col 1 you have 0 when the min is 2

Good catch, wonder how I missed that

Elements to pick


     [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8]

[1,]    0    0    0    2    2    2    1    4

[2,]    8    0    0    1    1    2    4    1

[3,]    0    1    2    1    0    2    2    1

[4,]    4    1    2   12    1    0    1    1

[5,]    0    1    2    1    1   11    0    2

[6,]    1    0    1    0    0    0    1    1

[7,]    2    0    4   10    1    2    0    0

Row sum

11 17 9 22 18 4 19

Column sum

15 3 11 27 6 19 9 10

Total points

570

Link to comment
Share on other sites

  • 0

Final answer:

I reworked the whole thing from the begining and

585


    0      0      0    -14     10     10    -11     44  =  39

  112      0      0      9     -4    -26     56      1  = 148

    0      1     14     -6      0     -6     -6      3  =   0

   96    -10    -28    144    -11      0     -4     -4  = 183

    0    -11     16    -12      1    154      0    -24  = 124

   -1      0      2      0      0      0     -8     -5  = -12

  -18      0     11    110    -10     10      0      0  = 103

In row 4 you have total of 26 elements. The limit is 6-22, though.

Edited by bushindo
Link to comment
Share on other sites

  • 0

In row 4 you have total of 26 elements. The limit is 6-22, though.

Ok I know how I missed that lol I noticed that none, except col 7, added even close to the limit so i didn't even look at the limits for the rows.

Your answer is correct, I think, when I worked it again. Congratulations!

Link to comment
Share on other sites

  • 0

0 0 0 0 0 0 0 44 =44

112 0 27 27 0 0 112 0 =278

24 3 0 0 0 0 0 0 =27

0 0 0 144 0 0 0 0 =144

0 0 0 0 0 154 0 0 =154

0 0 0 10 24 0 0 0 =34

0 0 132 110 0 0 0 0 =242

Total= 923

Edited by Born to Win
Link to comment
Share on other sites

  • 0

Please post how many of each element you picked. The highest I found tied with Bushindo's solution, although it picked different elements than Bushindo did. I'd like to check yours.

I deleted the working file after posting the solution... but will redo it

Link to comment
Share on other sites

  • 0

Well I reworked and guess what - its the total is the same as you got

post-17784-12517903880372.jpg

I guess yesterday, I may have made a mistake of adding an extra "14" in the minimum (i,j) to be taken which I noticed today came to -91 and yesterday it was -77!

The total of 100 numbers comes to 570 indeed

Link to comment
Share on other sites

  • 0

Well I reworked and guess what - its the total is the same as you got

post-17784-12517903880372.jpg

I guess yesterday, I may have made a mistake of adding an extra "14" in the minimum (i,j) to be taken which I noticed today came to -91 and yesterday it was -77!

The total of 100 numbers comes to 570 indeed

Thanks. Your choices are precisely those that I got. I suppose that's the highest you can go.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...