If you hang out in the Jobs Discussion forum much, fairly often someone will come in asking what questions people get asked on job interviews. Invariably someone will mention some little programming/algorithmic problem they were given that flustered them at the time (being asked on the spot and all).
In a recent thread the following interview question was mentioned:
Given an unsigned 16 bit integer and unlimited memory, provide an alogorithm which will determine the bits that are set.
and the following solution was given:
convert the # to binary
create a character array to store the bit pattern.
parse through the array and print out the indexes of the '1's. That was it!
Not satisfied with that solution I ran off to quickly see how many different ways I would solve this without resorting to the IMHO less than satisfactory answer this gentleman was given by his interviewer. It got me thinking how many others might have done the same thing.
A new forum, Other->Programming Diversions possibly, where people can present small programming challenges of varying difficulty, with the above as an example. Kind of a programatic Meaningless Drivel.
Problems of all difficulty levels should be encouraged. People would benefit not only by going through the exercises themselves, but seeing how others would solve the same problems.
Anyway, just a suggestion.
While in essence we are discussing algorithms, I personally would avoid the term for a couple of reasons. For one thing, it can be an intimidating topic for many people. For another, algorithms don't come off as being an overly exciting topic of discussion, IMHO. By keeping the emphasis on the fun and challenging aspects of problem solving, I feel you would maximize participation and therefore maximize the educational value. So in other words, yes we are basically talking about algorithms, but how you package it can make a difference.
[ June 12, 2002: Message edited by: Jason Menard ]
One source of many interesting problems is topcoder. This could keep you busy for months (hell, years if you don't know enough about algorithms...). What is a contest if not "fun and challenging"? Maybe we need some sort of JavaRanch contest...
My college algorithms class left a bad taste in my mouth I think. The course was so insanely difficult that, if I remember correctly, it had a curve that gave scores between 30%-50% (or somewhere around there anyway) a C grade. The individual who taught the course designed his tests so that scores in the 50's and below were the norm rather than the exception. You leave that course feeling you only learned about half of what he was trying to teach. It was very demoralizing on the whole.
Originally posted by Michael Ernest:
I like the idea of a 'Programming Diversions' forum in Other, where all you brain-teaser freaks can hang out and frustrate each other beyond belief (in Java, naturally).
Naturally Jim Yingst should moderate. :roll:
*Now* I like it! If Jim will be a moderator, I promise to move my focus of attention from MD to 'Programming Diversions'
If to speak about fun, there are a lot of good stuff on the I., Only one example: http://www.nyx.net/~gthompso/quine.htm
[ June 12, 2002: Message edited by: Mapraputa Is ]
For the title of the proposed forum - "Programming Diversions" works, certainly. Other possibilities that come to mind are:
Hmmm... Jason's original title is the most straightforward I suppose; I just like the idea of making the analogy with MD more explicit. Maybe it's just me though...
[ June 12, 2002: Message edited by: Jim Yingst ]
Originally posted by Jason Menard:
While in essence we are discussing algorithms, I personally would avoid the term for a couple of reasons. For one thing, it can be an intimidating topic for many people. For another, algorithms don't come off as being an overly exciting topic of discussion, IMHO.
These are all valid arguments. But I noticed that people who are good at logical thinking tend to look down at not-so-serious stuff. If we used combined title like "Algorithms and Programming Diversions", we could keep both parts of audience (or, perhaps, disgust both )
A dedicated forum for "Meaningless Programming" wont get too much traffic, I am afraid. I personally would vote for one united forum. And this way we can make David happy too.
Of course, right now I'm in LA, Palm, Springs, and Las Vegas until the 24th. And then DC and NYC until about July 2nd, so I won't be posting much until I get back in July.
PS Never fear putting me on the spot. I have strong views & opinions and the ability to back them up; but if no one ever challenges me on those positions, my ability will wither, and I'll just be full of hot air.
thread was here
I'm amazed I could find that thread. Maybe our first challenge is to design a search algorithm for a web site that doesn't suck, AND doesn't crash the server :roll: