The [Challenge] Index

Where we keep all the boring tidbits about the PHPDN site, the news, and what not.

Moderator: General Moderators

User avatar
onion2k
Jedi Mod
Posts: 5263
Joined: Tue Dec 21, 2004 5:03 pm
Location: usrlab.com

The [Challenge] Index

Post by onion2k »

[Challenge] threads are essentially puzzles. Someone (you!) can post a question that would be interesting to see various solutions to. Just pop [Challenge] in the thread subject somewhere.

When someone posts a [Challenge] thread it'll be linked to here so they're easy to find again:

Code: Select all

.....................................................
: Challenge                          : Author       :
:....................................:..............:
: [url=http://forums.devnetwork.net/viewtopic.php?t=105200]Database Connection[/url]                : klevis miho  :
: [url=http://forums.devnetwork.net/viewtopic.php?t=105220]Secret Decoder Ring[/url]                : McInfo       :
: [url=http://forums.devnetwork.net/viewtopic.php?t=105238]What color is the text?[/url]            : onion2k      :
: [url=http://forums.devnetwork.net/viewtopic.php?t=105337]Draw a chess field[/url]                 : klevis miho  :
: [url=http://forums.devnetwork.net/viewtopic.php?t=105420]Snakes and ladder style board[/url]      : mikemike     :
: [url=http://forums.devnetwork.net/viewtopic.php?t=105592]largest factorial[/url]                  : jazz090      :
: [url=http://forums.devnetwork.net/viewtopic.php?t=106110]Array Reversing button[/url]             : lunaticrabic :
: [url=http://forums.devnetwork.net/viewtopic.php?t=106119]Colour rotation[/url]                    : SimonMayer   :
: [url=http://forums.devnetwork.net/viewtopic.php?t=106143]Create a Form Description Language[/url] : joeynovak    :
: [url=http://forums.devnetwork.net/viewtopic.php?t=106495]Seeing Stars (and a Diamond)[/url]       : McInfo       :
: [url=http://forums.devnetwork.net/viewtopic.php?t=106778]Make a functional calendar[/url]         : Griven       :
: [url=http://forums.devnetwork.net/viewtopic.php?t=107654]Images the Hard Way[/url]                : McInfo       :
: [url=http://forums.devnetwork.net/viewtopic.php?t=108087]The Coder Cypher[/url]                   : Weiry        :
: [url=http://forums.devnetwork.net/viewtopic.php?f=1&t=110387&start=0&st=0&sk=t&sd=a]Zig-Zag Traversal[/url]                  : VladSun      :
:....................................:..............:
(Thanks to McInfo for the fancy table thing)
User avatar
jackpf
DevNet Resident
Posts: 2119
Joined: Sun Feb 15, 2009 7:22 pm
Location: Ipswich, UK

Re: The [Challenge] Index

Post by jackpf »

With kudos to ~klevis miho of course for originally coming up with the idea :P
User avatar
Benjamin
Site Administrator
Posts: 6888
Joined: Sun May 19, 2002 10:24 pm

Re: The [Challenge] Index

Post by Benjamin »

The moderation team has been discussing ideas for challenges and we think that it's a very good idea. We invite everyone to get involved in solving and coming up with ideas for challenges.
klevis miho
Forum Contributor
Posts: 413
Joined: Wed Oct 29, 2008 2:59 pm
Location: Albania
Contact:

Re: The [Challenge] Index

Post by klevis miho »

You should really open a category for that man :)
User avatar
mikemike
Forum Contributor
Posts: 355
Joined: Sun May 24, 2009 5:37 pm
Location: Chester, UK

Re: The [Challenge] Index

Post by mikemike »

urvashi
Forum Newbie
Posts: 1
Joined: Fri Sep 11, 2009 5:57 am

Re: The [Challenge] Index

Post by urvashi »

astions wrote:The moderation team has been discussing ideas for challenges and we think that it's a very good idea. We invite everyone to get involved in solving and coming up with ideas for challenges.

nice
User avatar
VladSun
DevNet Master
Posts: 4313
Joined: Wed Jun 27, 2007 9:44 am
Location: Sofia, Bulgaria

Re: The [Challenge] Index

Post by VladSun »

There are 10 types of people in this world, those who understand binary and those who don't
User avatar
John Cartwright
Site Admin
Posts: 11470
Joined: Tue Dec 23, 2003 2:10 am
Location: Toronto
Contact:

Re: The [Challenge] Index

Post by John Cartwright »

faymy001
Forum Newbie
Posts: 2
Joined: Sun Jan 24, 2010 7:37 pm

Re: The [Challenge] Index

Post by faymy001 »

Testing
User avatar
timWebUK
Forum Contributor
Posts: 239
Joined: Thu Oct 29, 2009 6:48 am
Location: UK

Re: The [Challenge] Index

Post by timWebUK »

User avatar
VladSun
DevNet Master
Posts: 4313
Joined: Wed Jun 27, 2007 9:44 am
Location: Sofia, Bulgaria

Re: The [Challenge] Index

Post by VladSun »

There are 10 types of people in this world, those who understand binary and those who don't
sukrityt8
Forum Newbie
Posts: 1
Joined: Sun Mar 21, 2010 12:24 am

Re: The [Challenge] Index

Post by sukrityt8 »

[quote="Benjamin"]The moderation team has been discussing ideas for challenges and we think that it's a very good idea. We invite everyone to get involved in solving and coming up with ideas for challenges.[/quote]

That is great to know. I love to face new "challenges" LOL, although I am not (regretfully) always very good at solving them. But I keep trying ... ;)
Last edited by sukrityt8 on Fri Aug 20, 2010 4:34 am, edited 1 time in total.
User avatar
VladSun
DevNet Master
Posts: 4313
Joined: Wed Jun 27, 2007 9:44 am
Location: Sofia, Bulgaria

Re: The [Challenge] Index

Post by VladSun »

There are 10 types of people in this world, those who understand binary and those who don't
phu
Forum Commoner
Posts: 61
Joined: Tue Mar 30, 2010 6:18 pm

Re: The [Challenge] Index

Post by phu »

How about something practical?

Implement regex-based URL routing: Given a URL, passed by the web server to your front controller, find the most efficient way to match said arbitrary URL against an arbitrarily large list of URL regex's, with an emphasis on avoiding the overhead of repeated preg_match (or similar) calls.

Extra credit: Minimize the number of regex matches while still allowing duplicate named patterns in your URL regex's.

This is a problem I've worked with recently and would be interested in seeing more solutions to.
User avatar
onion2k
Jedi Mod
Posts: 5263
Joined: Tue Dec 21, 2004 5:03 pm
Location: usrlab.com

Re: The [Challenge] Index

Post by onion2k »

phu wrote:How about something practical?
I don't really think that's a good idea. The point of coding challenges is to find interesting and inventive solutions to arbitrary problems - it's very likely those solutions won't necessarily be the best ones from a readability, efficiency or practical point of view. If we use realistic scenarios people might take the code and use it on their websites, introducing all sorts of security and usability issues along the way.
Post Reply