Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase 12»»

There's a Lot to Learn From Even Simple Puzzles Expand / Collapse
Author
Message
Posted Monday, August 10, 2009 9:37 PM


Mr or Mrs. 500

Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500

Group: General Forum Members
Last Login: Today @ 12:38 PM
Points: 587, Visits: 2,550
Comments posted to this topic are about the item There's a Lot to Learn From Even Simple Puzzles


Best wishes,

Phil Factor
Simple Talk
Post #768343
Posted Monday, August 10, 2009 10:35 PM


SSC-Dedicated

SSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-Dedicated

Group: General Forum Members
Last Login: Today @ 10:08 PM
Points: 35,362, Visits: 31,899
Congratulations Barry! Now, I've gotta go see what the hell you did!

--Jeff Moden
"RBAR is pronounced "ree-bar" and is a "Modenism" for "Row-By-Agonizing-Row".

First step towards the paradigm shift of writing Set Based code:
Stop thinking about what you want to do to a row... think, instead, of what you want to do to a column."

(play on words) "Just because you CAN do something in T-SQL, doesn't mean you SHOULDN'T." --22 Aug 2013

Helpful Links:
How to post code problems
How to post performance problems
Post #768359
Posted Monday, August 10, 2009 10:46 PM


SSC-Dedicated

SSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-Dedicated

Group: General Forum Members
Last Login: Today @ 10:08 PM
Points: 35,362, Visits: 31,899
Phil and Joe, thanks for having that contest. There was a huge amount of participation, debate, and code comparison! I know you guys had to spend a heck of a lot of time wading through all of that and it's much appreciated!

Well done to all who took part, as well. Some really great concepts bubbled to the surface.


--Jeff Moden
"RBAR is pronounced "ree-bar" and is a "Modenism" for "Row-By-Agonizing-Row".

First step towards the paradigm shift of writing Set Based code:
Stop thinking about what you want to do to a row... think, instead, of what you want to do to a column."

(play on words) "Just because you CAN do something in T-SQL, doesn't mean you SHOULDN'T." --22 Aug 2013

Helpful Links:
How to post code problems
How to post performance problems
Post #768363
Posted Tuesday, August 11, 2009 7:12 AM


SSCrazy Eights

SSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy Eights

Group: General Forum Members
Last Login: Wednesday, October 15, 2014 9:14 AM
Points: 9,294, Visits: 9,483
Woo-hoo! Finally, my name in lights!

Thanks, Phil and Joe. You too Jeff.

Fast though it was, my submission was far from elegant or simple. Despite our head-knocking and despite even the loop in it, I would say that Mike Ross's last submission impressed me the most for simplicity and elegance.


-- RBarryYoung, (302)375-0451 blog: MovingSQL.com, Twitter: @RBarryYoung
Proactive Performance Solutions, Inc.
"Performance is our middle name."
Post #768560
Posted Tuesday, August 11, 2009 7:47 AM


Mr or Mrs. 500

Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500

Group: General Forum Members
Last Login: Today @ 12:38 PM
Points: 587, Visits: 2,550
It was a tricky competition to judge for several reasons. Firstly, the entries were of such a high standard. Then they evolved, forked and cross-pollinated. It was also interesting to see the mutual help going on. It was like watching a horse-race where the front-running horses harnessed themselves together and crossed the finish line together. Actually, there were horses everywhere since some people seemed to end up with three or more submissions.

Joe was very taken by the way that everyone had taken the trouble to read up on the theory of calculating primes and brought that knowledge to the task.

We certainly agonised about whether the use of the number table should have been taken into account in the timings. however, we felt that because Joe had hinted that we wanted contestants to use that, we felt we should take a broader view of the general presentation, portability, documentation of the code etc, as well as sheer performance, so it never became the key issue.

Well done to all the contestants; even the solution that I killed after it had taken 17 hours to calculate primes below 1000. It was fun to judge.



Best wishes,

Phil Factor
Simple Talk
Post #768596
Posted Tuesday, August 11, 2009 8:02 AM


SSC-Dedicated

SSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-Dedicated

Group: Administrators
Last Login: Today @ 6:53 PM
Points: 31,177, Visits: 15,623
I, too, was amazed by the response to this. My initial thoughts were that the 10 people that enjoy math and SQL would jump in and most would ignore it, but there is some great work in the comments there. When Phil pointed this out to me last week that there were 20+ pages of comments, I was stunned.

I think there is definitely something to learn, especially the thought process as people collaborated with each other to improve solutions.

Great Job!







Follow me on Twitter: @way0utwest

Forum Etiquette: How to post data/code on a forum to get the best help
Post #768620
Posted Tuesday, August 11, 2009 8:31 AM


SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Thursday, October 16, 2014 4:11 AM
Points: 2,397, Visits: 3,416
Congratulations Barry!
It's a good thing they accepted your late submission



N 56°04'39.16"
E 12°55'05.25"
Post #768661
Posted Tuesday, August 11, 2009 8:44 AM


Mr or Mrs. 500

Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500Mr or Mrs. 500

Group: General Forum Members
Last Login: Today @ 12:38 PM
Points: 587, Visits: 2,550
I loved your routine, Peso. It was great to follow the forum postings, and see the way that you quietly submitted it but it seemed to take a while for the other contestants to see how radically it performed!


Best wishes,

Phil Factor
Simple Talk
Post #768672
Posted Tuesday, August 11, 2009 8:44 AM


SSCrazy Eights

SSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy EightsSSCrazy Eights

Group: General Forum Members
Last Login: Wednesday, October 15, 2014 9:14 AM
Points: 9,294, Visits: 9,483
Peso (8/11/2009)
Congratulations Barry!
It's a good thing they accepted your late submission

True, and thanks again to you Peter for pointing out the bugs in my original solution so that I had a chance to fix them!


-- RBarryYoung, (302)375-0451 blog: MovingSQL.com, Twitter: @RBarryYoung
Proactive Performance Solutions, Inc.
"Performance is our middle name."
Post #768673
Posted Tuesday, August 11, 2009 12:05 PM


SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Thursday, October 16, 2014 4:11 AM
Points: 2,397, Visits: 3,416
Thank you!
You did the hard work. I did nothing but finding some "edge" conditions for you to fix.



N 56°04'39.16"
E 12°55'05.25"
Post #768860
« Prev Topic | Next Topic »

Add to briefcase 12»»

Permissions Expand / Collapse