mersenneforum.org May 2022
 Register FAQ Search Today's Posts Mark Forums Read

 2022-05-02, 15:31 #1 Max0526   "Max" Jun 2016 Toronto 25×29 Posts May 2022
 2022-05-02, 15:37 #2 Max0526   "Max" Jun 2016 Toronto 11101000002 Posts It seems that the May challenge is too easy. Python produces the first solution for the regular challenge in under a second, and the the first bonus "*" solution in under 3 minutes on one core.
2022-05-02, 16:58   #3
uau

Jan 2017

149 Posts

Quote:
 Originally Posted by Max0526 It seems that the May challenge is too easy. Python produces the first solution for the regular challenge in under a second, and the the first bonus "*" solution in under 3 minutes on one core.
Even that is slower than necessary - there's a straightforward O(n2) algorithm.

By the way, the way to present the problem feels slightly weird to me - the introduction about how every size 2n set contains a size n subset with sum divisible by n doesn't seem to have all that much to do with actual problem. The added constraint removes most of the similarity, as there generally isn't a solution any more for arbitrary lists (consider a list starting with a pair of ones and the rest zeros).

 2022-05-02, 17:12 #4 ryanp     Jun 2012 Boulder, CO 409 Posts Also feels too simple... my dumb (recursive) Python program is about 15 lines and produces a solution for the first part in a few milliseconds, the second one in 3 seconds.
2022-05-05, 15:35   #5
Max0526

"Max"
Jun 2016
Toronto

25×29 Posts

Quote:
 Originally Posted by ryanp Also feels too simple... my dumb (recursive) Python program is about 15 lines and produces a solution for the first part in a few milliseconds, the second one in 3 seconds.
As a proof of concept, I wrote a long one-line solution in Python.
A 300 loop usually guarantees a solution for both (regular and bonus *) challenges.

2022-05-06, 19:37   #6
SmartMersenne

Sep 2017

7·19 Posts

Quote:
 Originally Posted by Max0526 As a proof of concept, I wrote a long one-line solution in Python. A 300 loop usually guarantees a solution for both (regular and bonus *) challenges.
I would love to see that one line after the challenge is over.

2022-05-11, 14:07   #7
Max0526

"Max"
Jun 2016
Toronto

25·29 Posts

Quote:
 Originally Posted by SmartMersenne I would love to see that one line after the challenge is over.
Do you want me to drop it via PM?

 2022-05-11, 14:09 #8 Max0526   "Max" Jun 2016 Toronto 25×29 Posts The first names are posted, seven of my students among them: https://research.ibm.com/haifa/ponde...s/May2022.html.
2022-05-12, 06:25   #9
tgan

Jul 2015

3·11 Posts

Quote:
 Originally Posted by Max0526 The first names are posted, seven of my students among them: https://research.ibm.com/haifa/ponde...s/May2022.html.
That is very good sign that you are excellent professor

Last fiddled with by tgan on 2022-05-12 at 06:26

2022-05-12, 07:03   #10
SmartMersenne

Sep 2017

7×19 Posts

Quote:
 Originally Posted by Max0526 The first names are posted, seven of my students among them: https://research.ibm.com/haifa/ponde...s/May2022.html.
103 solvers!

 Similar Threads Thread Thread Starter Forum Replies Last Post Xyzzy Puzzles 7 2022-06-04 19:54 tgan Puzzles 21 2022-03-23 21:59 Xyzzy Puzzles 7 2022-03-21 10:45 Xyzzy Puzzles 25 2022-02-14 01:08

All times are UTC. The time now is 15:16.

Sat Aug 13 15:16:36 UTC 2022 up 37 days, 10:03, 2 users, load averages: 0.76, 0.92, 0.98