• (cs) in reply to wiseguy
    Anonymous:
    Tsktsk. Did someone mention computers?

    Yeah, I actually thought that answer was funny, the filtering we all do every day.
  • (cs) in reply to rbriem
    rbriem:
    My country isn't utopian. It's predominantly capitalist. And we value education enough not to make it free beyond 12th grade.

    I take it you're American? I'm from Sweden. Our education is free, all through your life. You can study however much you want as long as you can support yourself. You only get student loans for six years though (or is it five now?, can't remember). As for the "value education enough not to make it free", you might be interested to know that (among other countries) Sweden, along with Norway, Denmark, Finland, Germany and Japan --all countries with free higher education-- in international academic comparative tests all beat America. I'm not some disgruntled European taking a shot at the US here, I'm just reacting against that old-but-still-prevalent myth that charging for education imrpves its quality, when it's all about the culture in which the education is provided.
  • (cs) in reply to Mikademus
    Mikademus:
    I'm from Sweden. Our education is free, all through your life.

    No, it's really not, as the Swedish income tax rate is somewhere between 33% to 60% per person, right? Let's not kid ourselves; you pay either way, somehow.

  • (cs) in reply to ParkinT
    ParkinT:

    Transcript (excerpt) from an actual interview for a high level developer.

    After a series of questions and from a candidate who had lots of "letters after his name" the following question was posed:

    <FONT color=#808080>Q: </FONT>Describe the Internet

    Long, thoughtful period of concentration, then

    <FONT color=#808080>A: </FONT>Object Oriented

     

    Nothing more, no expression of sarcasm.  No surprise he was not hired.

    I'm sorry, but if I got asked to describe the internet in a job interview, I wouldn't be interested in the job.

  • Jane (unregistered) in reply to wiseguy
    I can't think of a method of doing memory lookups without it essentially boiling down to a binary search or some slower method. Even if you do it in parallel you have to split and join the signal log2(n) times.


    Which is why you should look at how hash tables work. Performance is dependent on the hash algorithm both in terms of efficiency and effectiveness, but the initial hashlookup is via an array index derived from the hash modulo table size. Collisions are then typically resolved with a linear search.

    Tsktsk. Did someone mention computers?


    Lol, yeah, fair point.
    Bayesian filtering is the answer though. We typically receive about 200 to 300 spams a day caught by our stats based filter, and zero false positives. It's really incredibly effective. We catch others via rule based filters, and that catches almost all of the remaining dregs but with some false positivies. There are relatively so few though a human neural net can handle it without too much pain :)

  • (cs) in reply to Omnifarious
    Omnifarious:
    frosty:
    Agreed.  My company does background checks on all incoming employees.

    I won't work for places that do that. I'll give them references. I'll take tests.  I'll answer any question put to me that's related to the job, and some that aren't. But I will not submit to a background check.

    I don't have anything unpleasant they'd find aside from a less than stellar (but certainly not abysmal) credit history. But it's a principle thing. I don't do drug tests either, though the only drugs I take are OTC cold type stuff (and no, I'm not a Robotussin addict), alchohol and caffeine.

    If they can't figure out that I'm worth the price by asking me good questions, then I probably won't like working there anyway.

    You can thank lawyers, not the company management for the prevalance of background checks now.  Kind of like diving boards -- there aren't any anymore, sadly.

  • (cs) in reply to Djinn

    Djinn:

    Cuba has free doctorate level schooling. Not only for Cubans but for many people from around the world. That is a country that values education.

    So is everyone in Cuba well-educated?  Would Cuba be Utopia if it weren't for the US holding them back?

  • Ferris (unregistered) in reply to mister r

    A few simple, easy questions, any properly educated person in computer science should be able to answer:

    WTF?  Maybe someone with a doctorate. :|

    > 1. The fastest heuristic searching algorithm is A*, what are the constraints on possible evaluation functions you can use?

    Just because you studied algorithm X doesn't mean everyone else's curriculum covered that.

    > 2. Whats the minimum algorithmic complexity for parsing a context-free-language? (like for example XML)
    > 3. Whats the difference between parrelism and concurrency?
    > 4. Imagine that you need a function that given a machine-integer, computes the faculty of that machine-integer. What would the minimum algorithmic complexity be? (warning: this might be a trick question!)
    > 6. Why do all 3D engines represent a vector (of 3 coordinates: x,y,z) as a matrix of 4 by 4? Whats the benefit?
    > 8. What is the most common learning algorithm used for a spam filter?

    Yeah, everyone in CS also does this at the undergraduate level. :|

    > 5. Which dessign pattern would you choose to solve a sudoku puzzle?

    I'd use ML or Scheme, no design patterns needed.

    > 5. For which kind of keys, is a hash-table faster than a binary-search tree?

    According to our teacher, and big-O theory, hash tables are always faster.

    > 7. What is the difference between normal order evaluation and in order evaluation? (that is: strict and lazy evaluation?). Which programming languages are strict? Which are lazy?

    I believe every one we've studied is strict by default.

    > But when you need to write a chat-bot, a web-page crawler, a resource-planner, a 3d engine, a spam filter, a speech-recognition filter, a distributed raytracer, a compiler, etc.  you gonna need formal training.   
       

    Fair enough :)

  • (cs) in reply to graywh
    graywh:
    It's just 24! combinations.  This is first semester discrete math.

    If anyone else wants to refute the 24! answer, please enumerate all possibilities.  Until then, we'll just assume the real mathematicians are correct.


    Feh! You're assuming that all 24 ports must be connected. I can see how a mathematician might make such an assumption, but... (ah, yes, never miss a chance to mock a mathematician, an experimentalist, or anyone else who's not a theoretical physicist).
    Anyway, if you're allowed to connect any number of ports except none at all, and the cables really are identical, and there's really exactly 24 ports (no uplink or serial port or anything odd like that), there are 25!-1 ways to do it. I don't much feel like enumerating them right now, but I can email an enumeration of them to you if you wish.


  • doug (unregistered) in reply to Ferris

    >> 5. For which kind of keys, is a hash-table faster than a binary-search tree?

    >According to our teacher, and big-O theory, hash tables are always faster.

    Consider for a moment the set of keys for which the hash collides on every key.  Store this set of keys in the hash table, and in the binary-search tree.  Which data structure is faster for the lookup?

    The answer (I believe) to the original problem must be sets of keys for which the collision rate is lower than log(n)/n  (note, my rate calculation may be wrong, I did it in my head, but I think that's the exact answer, but it at least is the approximate answer).

  • Ribbly Screwspigot (unregistered) in reply to emurphy

    Anonymous:
    For all those 'experienced' but without college degree, claiming it makes no difference. A few simple, easy questions, any properly educated person in computer science should be able to answer:

    1. The fastest heuristic searching algorithm is A*, what are the constraints on possible evaluation functions you can use?

    2. Whats the minimum algorithmic complexity for parsing a context-free-language? (like for example XML)

    3. Whats the difference between parrelism and concurrency?

    5. Which dessign pattern would you choose to solve a sudoku puzzle?

    4. Imagine that you need a function that given a machine-integer, computes the faculty of that machine-integer. What would the minimum algorithmic complexity be? (warning: this might be a trick question!)

    5. For which kind of keys, is a hash-table faster than a binary-search tree?

    6. Why do all 3D engines represent a vector (of 3 coordinates: x,y,z) as a matrix of 4 by 4? Whats the benefit?

    7. What is the difference between normal order evaluation and in order evaluation? (that is: strict and lazy evaluation?). Which programming languages are strict? Which are lazy?

    8. What is the most common learning algorithm used for a spam filter?


    Yeah... my degree is in computer science and engineering and I have a math minor and I can honestly say I did not retain enough knowledge to answer those questions intelligently. Partly it's because I probably retained a maximum of 10% of what I learned in college, and also because in the couple of years I've been out of school, I haven't gone back to look at that stuff. I've been doing enterprise application development.

    I can maybe BS my way through 2 of those questions.

    On the other side of that coin, how useful is knowledge like this to most people in computers? These sound like exam questions for a graduate-level game programming course.

     

    See you in the bar,

    Ribbly

  • Ferris (unregistered) in reply to doug

    >>> 5. For which kind of keys, is a hash-table faster than a binary-search tree?

    >>According to our teacher, and big-O theory, hash tables are always faster.

    >Consider for a moment the set of keys for which the hash collides on every key.  Store this set of keys in the hash table, and in the >binary-search tree.  Which data structure is faster for the lookup?

    Did I really have to specify that it required a good hash-function?  Isn't that always implicit when discussing hash-tables?  Since we're being jackasses here, I'll just assume that the binary search tree is extemely unbalanced and both the hash table and the binary search tree have linear performance.  Happy now?

  • (cs) in reply to Ribbly Screwspigot
    Anonymous:
    On the other side of that coin, how useful is knowledge like this to most people in computers? These sound like exam questions for a graduate-level game programming course.

    I'd say undergraduate courses, but with a focus on AI.

    I too would not have gotten most of those questions, because I too am ~10 years after my schoolling. I do know that some of those I never would have got, even when I was in school. My focus was not on AI, so I did not get an introduction to A*.

    I suspect that if I had made such a list when I was in school, I would have found questions that seem basic and obvious that he would not have got - because I studied a different track than he is. (Don't ask me now, I've forgotten a lot)

  • doug (unregistered) in reply to Ferris

    >>>> 5. For which kind of keys, is a hash-table faster than a binary-search tree?

    >>>According to our teacher, and big-O theory, hash tables are always faster.

    >>Consider for a moment the set of keys for which the hash collides on every key.  Store this set of keys in the hash table, and in the >binary-search tree.  Which data structure is faster for the lookup?

    >Did I really have to specify that it required a good hash-function?  Isn't that always implicit when discussing hash-tables?  Since we're being jackasses here, I'll just assume that the binary search tree is extemely unbalanced and both the hash table and the binary search tree have linear performance.  Happy now?


    The original question essentially asked about what keys violate the expected performance guarantee.  Those are the keys.  And the result for those keys is that even if in fact the binary search tree is maximally unbalanced and the search is also linear, so is the hash table, and so it is not faster.

    This is a practical flaw you can actually hit in the real world.  You think you have a good hash, but later discover that you have some interesting subset of the keyspace with a high collision rate.

    I guess potentially there's another answer involving small sets of keys where the linear cost of computing the hash is larger than log(n).

  • doug (unregistered) in reply to Ribbly Screwspigot

    >On the other side of that coin, how useful is knowledge like this to most people in computers? These sound like exam questions for a graduate-level game programming course.

    Indeed, except for the spam filter question, I'd have said this was clearly a list of questions for someone specialized in games/AI.  I doubt if one in ten people who get a BS in CS get exposed to all of those issues in their curricula.  Maybe Games & AI is right.  In any case, I would not use any of these questions to interview someone for a job at my company, not a one of them would give me a useful idea of whether or not the person could do useful work for me.

  • (cs) in reply to Mikademus
    Mikademus:
    As for the "value education enough not to make it free", you might be interested to know that (among other countries) Sweden, along with Norway, Denmark, Finland, Germany and Japan --all countries with free higher education-- in international academic comparative tests all beat America. I'm not some disgruntled European taking a shot at the US here, I'm just reacting against that old-but-still-prevalent myth that charging for education imrpves its quality, when it's all about the culture in which the education is provided.

    I can't speak for the rest, but the fact that Germany is inn your list shows just how bad the comp tition is. Historically (I say historically because Germany has in recent years recognized that their policy does not work and is changing this for the better - but the process is not done) German education. They evaluate your progress through the years, if you are not doing well (better than average) in school by third grade they cut you off from regular education and start moving you a job focused education.

    So if you are a great student, German schools are great. Probably better than any other country, because you don't have to sit around bored while the teacher tries to explain something to your less

    I suspect the competition was among the best in each country. In that case it is more how the contest is structured, and luck, than which education system is better.

    As for the US, Do recall that we are a big country. If North Dakota (For those who don't know, North Dakota has essentially no industry, just a agricultural area, and it is nearly a desert) was a separate country, their education system would rank as among the best in the world. However they are part of the US which also has states like Mississippi with some of the worst education in the world.

    If the EU was all combined, their overall education would be worse than Sweden's.

  • (cs) in reply to Mikademus
    Mikademus:
    rbriem:
    My country isn't utopian. It's predominantly capitalist. And we value education enough not to make it free beyond 12th grade.

    I take it you're American? I'm from Sweden. Our education is free, all through your life. You can study however much you want as long as you can support yourself. You only get student loans for six years though (or is it five now?, can't remember). As for the "value education enough not to make it free", you might be interested to know that (among other countries) Sweden, along with Norway, Denmark, Finland, Germany and Japan --all countries with free higher education-- in international academic comparative tests all beat America. I'm not some disgruntled European taking a shot at the US here, I'm just reacting against that old-but-still-prevalent myth that charging for education imrpves its quality, when it's all about the culture in which the education is provided.


    Citing academic tests to argue the value of education is technically correct, although 'pragmatists' would argue that per capita GDP is more important to quality of life of the average citizen (not the issue you addressed, I know, but I'd argue more imporant overall in my mind):
    http://www.cia.gov/cia/publications/factbook/rankorder/2004rank.html
    <br>
    Of course, education is only one factor in determing a nation's economic health and the US economy also benefits from a large influx of high-education immigrants.
  • Sam (unregistered) in reply to hank miller

    hank miller:
    Mikademus:
    As for the "value education enough not to make it free", you might be interested to know that (among other countries) Sweden, along with Norway, Denmark, Finland, Germany and Japan --all countries with free higher education-- in international academic comparative tests all beat America. I'm not some disgruntled European taking a shot at the US here, I'm just reacting against that old-but-still-prevalent myth that charging for education imrpves its quality, when it's all about the culture in which the education is provided.
    I can't speak for the rest, but the fact that Germany is inn your list shows just how bad the comp tition is.  In that case it is more how the contest is structured, and luck, than which education system is better. As for the US, Do recall that we are a big country. If North Dakota (For those who don't know, North Dakota has essentially no industry, just a agricultural area, and it is nearly a desert) was a separate country, their education system would rank as among the best in the world.

    I appreciate your skepticism, hank, but the US public educational system has some very serious flaws.  A recent test run by ABC News compared students in a better-than-average NJ high school to Belgian students on a test (and NJ schools are among the top in the nation).  Are there flaws?  Sure, use of the metric system exclusively being one, and if the questions were from the standard international comparison test, some of the answers are technically inaccurate (particularly in civics).  However, the results were startlingly different, more so than the biases inherent in the tests would suggest.

    However, here's my main point:  it's the free part of the educational system (i.e., public school grades 1-12) that's screwed up in America.  The private university system does rather well, many other countries send their citizens to America for post-high school education, and some other countries' systems of higher education (Japan in particular) are regarded as low quality in their own country.

  • miah (unregistered) in reply to emurphy
    emurphy:
    Furrfu!  Intuitively, wouldn't you just connect a cable from the 1 end of one 24-to-1 hub to one of the 24 ends of the other 24-to-1 hub, effectively turning them into a single 47-to-1 unit?  (Not a troll; I'm a software guy, not a network guy, so this is an honest educated guess.)



    Well actually, many 3com switches have two ports *on the back* that allow you to connect to another hub, provided you have the special cable.  So you could easily create a 48 port hub with two 24 port hubs, and since each of these hubs have two ports you can continue to add additiona hubs until your network is too laggy to function properly.

    -miah
  • (cs) in reply to Otto
    Otto:
    Mikademus:
    I'm from Sweden. Our education is free, all through your life.

    No, it's really not, as the Swedish income tax rate is somewhere between 33% to 60% per person, right? Let's not kid ourselves; you pay either way, somehow.

    True, our tax pressure is quite outstanding. However, those taxes covers medical treatment, retirement, civic services, libraries, social securities, in all, a pervasive package of that word "wellfare" that I understand has a quite negative connotation over the pond. I read a study showing that even though Sweden has a high tax pressure, adjusted for private medical insurance etc etc, the real purchasing power of Swedes and Americans is very similar.
  • (cs)


    ...

    claimed he was a Cisco Certified Engineer. ... A small sized downtown office needed to increase there network port capacity by adding an additional 24 port 3Com hub (when hubs were all the rage), adding to their already existing one.

    ...



    Of course! Clearly if he's *Cisco* certified then he couldn't possibly be expected to figure out how that alien *3Com* hub technology works!
  • (cs) in reply to doug
    Anonymous:
    In any case, I would not use any of these questions to interview someone for a job at my company, not a one of them would give me a useful idea of whether or not the person could do useful work for me.

    Right on, brother.

    In the interview, I'll ask some tough questions, but they would be more focused on the application of a theory, rather than a discourse on the theory itself. I expect the candidate to not know the answer, but I need to see how they react when faced with a problem they can't solve. Kind of like a Kobayashi Maru* for software engineers.

    <font size="1">*ugh, I'm such a geek.</font>
  • ChiefCrazyTalk (unregistered) in reply to JohnO
    JohnO:
    ParkinT:

    Transcript (excerpt) from an actual interview for a high level developer.

    After a series of questions and from a candidate who had lots of "letters after his name" the following question was posed:

    <FONT color=#808080>Q: </FONT>Describe the Internet

    Long, thoughtful period of concentration, then

    <FONT color=#808080>A: </FONT>Object Oriented

     

    Nothing more, no expression of sarcasm.  No surprise he was not hired.

    I'm sorry, but if I got asked to describe the internet in a job interview, I wouldn't be interested in the job.

     

    Actually, I kind of like that question.  Its open-ended, which means you might get an answer that didn't come straight from the "Teach yourself visual basic in 24 days" book.

     

    My two favorite interview questions are as follows:

    1.  If you could be any kind of fruit, what kind of fruit would you be?  (I was actually asked this once as an undergrad!)

    and the all time classic Microsoft interview question

     

    2.  Why are manhole covers round?

  • (cs) in reply to ChiefCrazyTalk
    Anonymous:
    JohnO:
    ParkinT:

    Transcript (excerpt) from an actual interview for a high level developer.

    After a series of questions and from a candidate who had lots of "letters after his name" the following question was posed:

    <font color="#808080">Q: </font>Describe the Internet

    Long, thoughtful period of concentration, then

    <font color="#808080">A: </font>Object Oriented

     

    Nothing more, no expression of sarcasm.  No surprise he was not hired.

    I'm sorry, but if I got asked to describe the internet in a job interview, I wouldn't be interested in the job.

     

    Actually, I kind of like that question.  Its open-ended, which means you might get an answer that didn't come straight from the "Teach yourself visual basic in 24 days" book.

     

    My two favorite interview questions are as follows:

    1.  If you could be any kind of fruit, what kind of fruit would you be?  (I was actually asked this once as an undergrad!)

    and the all time classic Microsoft interview question

     

    2.  Why are manhole covers round?



    1.  Uhh.  I don't want to be a fruit.  I'd rather be a nut.  Specifically, a Beer Nut.  (And if any biologist points out that nuts are fruit, I'll smash my head against my desk.  It's been that kind of day, already).

    2.  Okay, is this a trick question?  I mean, everyone knows that they're round so they won't fall in, right?  Or am I the idiot?

    Ugh.  TGIF and all that.  Too bad I'm on call this weekend.

  • (cs) in reply to Mikademus
    Mikademus:
    True, our tax pressure is quite outstanding. However, those taxes covers medical treatment, retirement, civic services, libraries, social securities, in all, a pervasive package of that word "wellfare" that I understand has a quite negative connotation over the pond. I read a study showing that even though Sweden has a high tax pressure, adjusted for private medical insurance etc etc, the real purchasing power of Swedes and Americans is very similar.

    I have no doubt that the purchasing power is similar, I was just arguing against your use of the word "free". TANSTAAFL and all that.
  • (cs) in reply to ChiefCrazyTalk
    Anonymous:

    2.  Why are manhole covers round?



    Unfortunately everyone knows this already.

    But, some manhole covers are not round.  What are some reasons you would *not* want a round manhole cover?
  • ChiefCrazyTalk (unregistered) in reply to John YaYa

     



    1.  Uhh.  I don't want to be a fruit.  I'd rather be a nut.  Specifically, a Beer Nut.  (And if any biologist points out that nuts are fruit, I'll smash my head against my desk.  It's been that kind of day, already).

    2.  Okay, is this a trick question?  I mean, everyone knows that they're round so they won't fall in, right?  Or am I the idiot?

    Ugh.  TGIF and all that.  Too bad I'm on call this weekend.

     

    Actually there are three generally accepted answers to question 2.  Yours is the one usually considered correct, but other equally valid answers are  1.  So the manhole covers can be moved around by rolling them, and 2.  Because the manholes are round.

  • (cs) in reply to Sam
    Anonymous:

    hank miller:
    Mikademus:
    As for the "value education enough not to make it free", you might be interested to know that (among other countries) Sweden, along with Norway, Denmark, Finland, Germany and Japan --all countries with free higher education-- in international academic comparative tests all beat America. I'm not some disgruntled European taking a shot at the US here, I'm just reacting against that old-but-still-prevalent myth that charging for education imrpves its quality, when it's all about the culture in which the education is provided.
    I can't speak for the rest, but the fact that Germany is inn your list shows just how bad the comp tition is.  In that case it is more how the contest is structured, and luck, than which education system is better. As for the US, Do recall that we are a big country. If North Dakota (For those who don't know, North Dakota has essentially no industry, just a agricultural area, and it is nearly a desert) was a separate country, their education system would rank as among the best in the world.

    I appreciate your skepticism, hank, but the US public educational system has some very serious flaws.  A recent test run by ABC News compared students in a better-than-average NJ high school to Belgian students on a test (and NJ schools are among the top in the nation).  Are there flaws?  Sure, use of the metric system exclusively being one, and if the questions were from the standard international comparison test, some of the answers are technically inaccurate (particularly in civics).  However, the results were startlingly different, more so than the biases inherent in the tests would suggest.

    However, here's my main point:  it's the free part of the educational system (i.e., public school grades 1-12) that's screwed up in America.  The private university system does rather well, many other countries send their citizens to America for post-high school education, and some other countries' systems of higher education (Japan in particular) are regarded as low quality in their own country.

    Mikademus -

    In my original post, I also said, "... this is part of our capitalist culture - the value we give to something is bound up in what we pay for it (or invest in it)."

    My point there is that this is the system that works best for us (as a society) in our capitalist culture. When things are free, we (as individuals) take them too much for granted. (And yes, that's America).

    And I'm not saying that simply charging for education improves its quality; again, in my original post, I mentioned that the people who had learned the least had gotten a free education (mainly via Parental Bank and Trust), even though they went to schools that weren't free. By not having to work out a way to pay for it (loans, grants, scholarships, sweat), they lacked the incentive to value the educational process, so they learned less. And that's a cultural issue that many of us don't (or refuse to) understand - I know I sure as hell didn't understand it when I was younger.

    As for culture, I personally value education enough to send my 2 youngest to private school, even though I already pay for public school through my taxes (long story short, changing the public system from within takes too long - been there, done that). They get a better education; not because it's paid for, but because a private school, being agile and non- (or at least less-) beholden to federal funds, provides a better culture for learning. Again, the administration and staff have the incentive to make it a better place because they have to work to make it (the school and their jobs) happen, rather than having it provided for them.

    And Sam (aka Anonoymous) -

    I agree with you on public schools. One of my older sons missed out on 4th grade math because his teacher didn't like to teach math (this was in a highly regarded school district). So he didn't. NO math for almost an entire year. Arg. Since it was "free" to the other parents, and "free" to the administration, no one (except my wife and I) saw an incentive to make change happen. But I'm not bitter. :)

  • mister r (unregistered) in reply to emurphy
    emurphy:
    Anonymous:

    Google and Wikipedia seem to turn up 3, second-5, 6, 7, 8 in short order, and the above background is enough for me to grok the answers (I think).

    First-5:  depth-first search, and a sensible grasp of different solving methods and which ones involve the least backtracking.

    How'm I doin'?



    Depth-first-search is an _algorithm_ not a design pattern. The design pattern in the case of the sudoku puzzle would _obviously_ be modelling it as a constraint-satisfaction-problem. Any sudoku puzzle can be translated into a set of equality constraints. Just like SEND+MORE=MONEY puzzles, or the 8-queens-problems.


    Well, yes, that's what the "which solving methods involve the least backtracking" bit is about.  Namely, which constraints can be satisfied most quickly.  And not just the constraints that derive directly from the problem definition, but also those that arise indirectly from the pigeonhole principle, and from simple two- or three- or etc.-step chains of deductive logic, and and and.  Things get somewhat less obvious there, though once again a few minutes with G and W will prevent you from reinventing well-known wheels.


    But depth-first-search would definately not be my pick. This is a very typical situation where conflict-backjumping will give you much better results. With depth-first-search the performance will depend very strongly on how you order your constraints. If the problematic constraint gets evaluated last, dfs is as slow as brute-force.  Rather you should adjust the order, to put the constraints causing problems up front, while you're searching.


    Again, that's what I meant in the first place.  I think this is an issue of terminology rather than actual intent.


    And about Wikipedia and Google giving you some start points based on _my_ terminoly is very misleading. In the real world problems don't present themselves to you together with a bag of related search-words.

    Secondly, and this is more shocking: the above are no puzzles. They are so  incredibly simpel and corner-stone of the whole foundation of CS that you really should be able to answer them immidiately. Sure, knowing 2 + 2 = 4  doesn't prove you're great at math. But those that need google (or, in the case of 2+2, a calculater) to get the answer aren't ready for anything more complicated than this.

    Not that it is a problem: like I said, the majority of programming is simple. Simple as in not-complex and not as in not-obfuscated. A lot of programming is obfuscated and it takes discipline to deal with it. Like Web-programming, when you're working with 2 - 4 languages at the same time. (Javascript, Php, Sql, XHtml) .. but its not _complex_. It takes organization and discipline and thats an important talent, but it doesn't require formal education, like the harder problems in the field do.


    And I think this represents a disconnect between your idea of CS and a lot of other people's idea of CS.  It's not just that 80% of the work is non-complex, it's that 80% of the people will stick to non-complex work (but it is  obfuscated, as you note, and we're unlikely to run out of it any time soon).  Most people will never have occasion to write their own 3-D engine, spam filter, compiler, etc etc etc.  (On the gripping hand, I honestly feel that I could write a Bayesian spam filter based on the Wikipedia article, at least after spending some more time studying how the individual per-word probabilities are merged into a single per-message probability.)

    Would you classify proper RDBMS design as complex?  I've gotten decent at table and view design over the years (in spite of college, not because of it; my DB teacher was an idiot), but still only grasp the basics of index optimization (I don't work on systems large enough to require the subtleties).



    Well, its like an architect. The first one to build a bridge using half an ellipse shape for stability was very smart. The 10,000 architects that just do that because the book said it would work are just good at their job. But I wouldn't call it complex when they are just utilizing the framework. But like you said, its all just terminilogy.

    Given a math background as you have, might just be very usefull for CS. The important thing is, you've problely learned that when it does get to 'complex', you formalize, and you can. My pop-quizz was only a reaction to all the 'im-not-educated-but-im-a-much-better-programmer-than-those-college-morans'.  They just don't know _what_ it is they don't know. Doubt is the first sign of intelligence in POV.





  • (cs) in reply to reed
    reed:

    But, some manhole covers are not round.  What are some reasons you would *not* want a round manhole cover?

    Have you tried fitting a square man in a round manhole?
  • James Schend (unregistered) in reply to John Smallberries

    Re: Manhole question...

    The obvious answer is, "so it can't fall in the hole."

    Then the interviewer is supposed to ask, "well, why don't they use an equilateral triangle cover then?"

    To which you can reply, "because it won't roll," or "because they'd have to use up more steel to be large enough so people can fit down them" or some other good reason.

    The classic anecdote about why Microsoft stopped asking this question is that supposedly (I've never been there), the Microsoft campus is full of those hinged rectangular utility covers and not traditional manholes, and when the interviewer asked, "why are manhole covers round?" the interviewee pointed out the window at one of the utility covers and said, "they aren't!"

  • (cs) in reply to reed
    reed:
    Anonymous:

    2.  Why are manhole covers round?



    Unfortunately everyone knows this already.

    But, some manhole covers are not round.  What are some reasons you would *not* want a round manhole cover?

    1. Because you have a manhole that isn't round ...

  • (cs) in reply to rbriem

    Because it saves resources to make them square or hexagonal?

  • (cs) in reply to mister r

    mister r:

    Depth-first-search is an _algorithm_ not a design pattern. The design pattern in the case of the sudoku puzzle would _obviously_ be modelling it as a constraint-satisfaction-problem. Any sudoku puzzle can be translated into a set of equality constraints. Just like SEND+MORE=MONEY puzzles, or the 8-queens-problems.

    Design Pattern...You keep using that word. I do not think it means what you think it means.

  • mister r (unregistered) in reply to doug
    Anonymous:
    >On the other side of that coin, how useful is knowledge like this to most people in computers? These sound like exam questions for a graduate-level game programming course.

    Indeed, except for the spam filter question, I'd have said this was clearly a list of questions for someone specialized in games/AI.  I doubt if one in ten people who get a BS in CS get exposed to all of those issues in their curricula.  Maybe Games & AI is right.  In any case, I would not use any of these questions to interview someone for a job at my company, not a one of them would give me a useful idea of whether or not the person could do useful work for me.



    Just normal 'standard' CS study. I haven't ever worked on any game. My favorite subjects are functional higher order programming (haskell, scheme, etc.) .. and I like making my own compilers and interpreters, but I actually refrained to ask questions about that, because i would be too tempted to make the questions hard because I personally find it so interesting. So I actually choose the topics based on things I don't care about.

    I don't really understand why this is associated with game-programming though, except the vector question.
      - Things like hash-tables are the basic datastructure of languages like python, lua, php, well even javascript.
      - Parsing XML is problely the most written parser the last few years due to the whole xml hype. Almost every language now has one, and any web programmer has used one at least.
      - A* is what any route-finding software would use. You have a navigator in your car right? So you've used this algorithm too!
      - Constraint-satisfaction-problems are AI, I agree, you use them to solve puzzles. OR: to deal with concurrency and distributed computation. Or: to implement a type checker. Any Java/C#/Haskell type checker essentially boils down to constraint-satisfaction.

    But perhaps the focus on our University is very geared towards AI and am I just assuming all this stuff applies everywhere. They make us write our own java compiler (in Haskell thankfully) in the second year :-)

    I wouldn't claim that writing compilers is something you would do often in your life, but the procces itself does teach you a lot of things that I will often use. Who figured that a compiler is just one big fold anyway ? Just slightly more complicated than summing up a list of numbers.
  • (cs) in reply to James Schend
    Anonymous:
    Re: Manhole question...
    The obvious answer is, "so it can't fall in the hole."
    Then the interviewer is supposed to ask, "well, why don't they use an equilateral triangle cover then?"

    Umm... Because an equilateral triangle could fall through the hole.

    Position it near one edge of the hole, with one side of the cover exactly vertical. The width of it will then be the distance from the center of the vertical edge to the opposite corner, which is 1/sqrt(2) or about 0.7. The edge is just under 1.0 long (considering there will be a lip). Poof, triangle slides right in.

  • mister r (unregistered) in reply to zip
    zip:

    mister r:

    Depth-first-search is an _algorithm_ not a design pattern. The design pattern in the case of the sudoku puzzle would _obviously_ be modelling it as a constraint-satisfaction-problem. Any sudoku puzzle can be translated into a set of equality constraints. Just like SEND+MORE=MONEY puzzles, or the 8-queens-problems.

    Design Pattern...You keep using that word. I do not think it means what you think it means.



    When I use the word, I refer to how to abstract away the underlying problems. In other words, the preffered method of slicing a problem into a more general one, and its constants. Like a fold is a generalization of a map. But thats my definition, whats yours' ?




  • (cs) in reply to Otto
    Otto:
    Anonymous:
    Re: Manhole question...
    The obvious answer is, "so it can't fall in the hole."
    Then the interviewer is supposed to ask, "well, why don't they use an equilateral triangle cover then?"

    Umm... Because an equilateral triangle could fall through the hole.

    Position it near one edge of the hole, with one side of the cover exactly vertical. The width of it will then be the distance from the center of the vertical edge to the opposite corner, which is 1/sqrt(2) or about 0.7. The edge is just under 1.0 long (considering there will be a lip). Poof, triangle slides right in.



    Actually, all that you've proven is that the hole can be at most 70% the width of the triangle.
  • (cs) in reply to Otto

    Argh. My trig skills are rusty. :(

    Replace 1/sqrt(2) in the above with sqrt(3/4) or about 0.86.. Doesn't change my point, just the number.

  • (cs) in reply to Maurits
    Maurits:
    Actually, all that you've proven is that the hole can be at most 70% the width of the triangle.

    86%, due to my bad math.

    But if you're going to take that approach, then the hole/cover can be any shape, since it's possible to shrink the hole enough that the cover won't fit no matter what the shape is, which completely ruins the point of the original question in the first place.

  • mister r (unregistered) in reply to rbriem
    rbriem:
    Anonymous:

    hank miller:
    Mikademus:
    As for the "value education enough not to make it free", you might be interested to know that (among other countries) Sweden, along with Norway, Denmark, Finland, Germany and Japan --all countries with free higher education-- in international academic comparative tests all beat America. I'm not some disgruntled European taking a shot at the US here, I'm just reacting against that old-but-still-prevalent myth that charging for education imrpves its quality, when it's all about the culture in which the education is provided.
    I can't speak for the rest, but the fact that Germany is inn your list shows just how bad the comp tition is.  In that case it is more how the contest is structured, and luck, than which education system is better. As for the US, Do recall that we are a big country. If North Dakota (For those who don't know, North Dakota has essentially no industry, just a agricultural area, and it is nearly a desert) was a separate country, their education system would rank as among the best in the world.

    I appreciate your skepticism, hank, but the US public educational system has some very serious flaws.  A recent test run by ABC News compared students in a better-than-average NJ high school to Belgian students on a test (and NJ schools are among the top in the nation).  Are there flaws?  Sure, use of the metric system exclusively being one, and if the questions were from the standard international comparison test, some of the answers are technically inaccurate (particularly in civics).  However, the results were startlingly different, more so than the biases inherent in the tests would suggest.

    However, here's my main point:  it's the free part of the educational system (i.e., public school grades 1-12) that's screwed up in America.  The private university system does rather well, many other countries send their citizens to America for post-high school education, and some other countries' systems of higher education (Japan in particular) are regarded as low quality in their own country.

    Mikademus -

    In my original post, I also said, "... this is part of our capitalist culture - the value we give to something is bound up in what we pay for it (or invest in it)."

    My point there is that this is the system that works best for us (as a society) in our capitalist culture. When things are free, we (as individuals) take them too much for granted. (And yes, that's America).

    And I'm not saying that simply charging for education improves its quality; again, in my original post, I mentioned that the people who had learned the least had gotten a free education (mainly via Parental Bank and Trust), even though they went to schools that weren't free. By not having to work out a way to pay for it (loans, grants, scholarships, sweat), they lacked the incentive to value the educational process, so they learned less. And that's a cultural issue that many of us don't (or refuse to) understand - I know I sure as hell didn't understand it when I was younger.

    As for culture, I personally value education enough to send my 2 youngest to private school, even though I already pay for public school through my taxes (long story short, changing the public system from within takes too long - been there, done that). They get a better education; not because it's paid for, but because a private school, being agile and non- (or at least less-) beholden to federal funds, provides a better culture for learning. Again, the administration and staff have the incentive to make it a better place because they have to work to make it (the school and their jobs) happen, rather than having it provided for them.

    And Sam (aka Anonoymous) -

    I agree with you on public schools. One of my older sons missed out on 4th grade math because his teacher didn't like to teach math (this was in a highly regarded school district). So he didn't. NO math for almost an entire year. Arg. Since it was "free" to the other parents, and "free" to the administration, no one (except my wife and I) saw an incentive to make change happen. But I'm not bitter. :)



    Very interesting, you make a very strong point here. Eventhough its hard to believe that a poor kid will get more out of his education than a rich kid, if only it was because he was working so hard to pay for his study. I know i've always taking it all for granted, but I know I few people that need to work lots and lots just to afford to go the college, not to mention, being socially accepted.

    Not that i'm opposed to capitalism, i'm only opposed to kids starting off differently, although I can not come up with any solution for that, that doesn't the scare the shit out of me when I think it.
  • (cs) in reply to Otto

    Otto:
    Anonymous:
    Re: Manhole question...
    The obvious answer is, "so it can't fall in the hole."
    Then the interviewer is supposed to ask, "well, why don't they use an equilateral triangle cover then?"

    Umm... Because an equilateral triangle could fall through the hole.

    Position it near one edge of the hole, with one side of the cover exactly vertical. The width of it will then be the distance from the center of the vertical edge to the opposite corner, which is 1/sqrt(2) or about 0.7. The edge is just under 1.0 long (considering there will be a lip). Poof, triangle slides right in.

    I was always nervous about that equilateral triangle. Thanks for confirming my fears. One minor correction: "distance from the center of the vertical edge to the opposite corner" is sqrt(3) / 2 or about 0.87. Your conclusion still holds, though.

  • (cs) in reply to Otto
    Otto:
    But if you're going to take that approach, then the hole/cover can be any shape


    They can.  Some manhole covers are, in fact, square.

    http://www.g4tv.com/screensavers/features/6282/Square_Manhole_Covers_and_Crazy_Questions.html

    So it was basically a bogus question to begin with, like "why did all the coelacanths die out."
  • (cs) in reply to Maurits

    Another answer I don't think I've heard is "usability."

    For a round shape, all you have to do is kick the cover towards the hole until it clicks.

    For almost any other shape, you have to orient the thing correctly.  And those things can be heavy.

  • (cs) in reply to Djinn
    Djinn:
    In fact, I'm doing  financially better than many of my friends who hold a BS (which is just that) or MS.


    The fact that you think anecdotal evidence regarding your "friends" has any place in this discussion shows your lack of knowledge. You should be ashamed.

    sincerely,
    Richard Nixon
  • (cs) in reply to Maurits
    Maurits:
    Another answer I don't think I've heard is "usability."


    Dammit Cecil Adams beat me to it.
    http://www.straightdope.com/classics/a1_247a.html
  • KeithSpook (unregistered) in reply to mister r

    My pop-quizz was only a reaction to all the 'im-not-educated-but-im-a-much-better-programmer-than-those-college-morans'.  They just don't know _what_ it is they don't know. Doubt is the first sign of intelligence in POV.

    I'm self-educated, not uneducated.  So it's My Turn (tm):

    1. How might a Hidden Markov Model be used in statisical NLP?

    2. Assuming that a surjective and and injective function exists between the Power Set P(A) and N, what can be said about P(A)?

    3. How does rebuilding an index in a database effect performance, if that index contains ~1.5 billion records with 10% deletions, assuming the index is implemented as a B*Tree?

    4. Elaborate on why Knuth is able to give away money for bugs found in TeX?

    5. Describe how a strike angle on a worm gear effects the force of the gear.

    The bummer is that I'm not educated enough to use this forum software.  So perhaps I should enroll at my local trade school.

  • mister r (unregistered) in reply to Ferris
    Anonymous:
    > A few simple, easy questions, any properly educated person in computer science should be able to answer:

    WTF?  Maybe someone with a doctorate. :|


    Well, i'm just in my 2nd year, and am by no means the very best student there is at my college.

    Anonymous:

    > 1. The fastest heuristic searching algorithm is A*, what are the constraints on possible evaluation functions you can use?

    Just because you studied algorithm X doesn't mean everyone else's curriculum covered that.


    A* is the -fastest- heuristic search algorithm and knowledge about it is mandatory for every one. But since no one got the question about this one right: You can use any heuristic function as long as it never under-estimatest the value. As far as I know, A* is the only place and way to use heuristic functions. They were dealed with just after depth-first-search and breadth-first search.

    So ehm, its mandatory: it did cover every ones curriculum and it did in the very first year in the same class where they also explain hash-tables, arrays, binary search trees, etc. Very common knowledge. The subject was called 'data-structures' and you're not even allowed to continue if you failed that subject.

    Anonymous:

    > 8. What is the most common learning algorithm used for a spam filter?

    Yeah, everyone in CS also does this at the undergraduate level. :|


    Yeah, they do. But it was not mandatory, it is still very common knowledge.
    And its being used everywhere, from determing wether or not a match will continue on Wimbledon (the tennis tournament) as for your spam filter, or to detect credit card fraud. Its also the core algorithm behind most marketing-collecting-datamining. Here in Holland, the biggest super-markets had special passes that give you discount. It helps them to know what you buy, where and when. Then they analyze that information using the very same Bayesian algorithm. The end-result is that most things I want to buy are actually laying next to each other.

    Anonymous:

    > 5. Which dessign pattern would you choose to solve a sudoku puzzle?
    I'd use ML or Scheme, no design patterns needed.


    Excellent choice of tool, but the tool doesn't solve the problem for you. Secondly because both Ml and Scheme are strict languages, any naive approach will be very slow. You would at least need to seperate generating from testing, but more preferebly seperate the searching.

    Anonymous:

    > 5. For which kind of keys, is a hash-table faster than a binary-search tree?
    According to our teacher, and big-O theory, hash tables are always faster.


    Well, the assumption here is that the keys are actually well distributed.

    Anonymous:

    > 7. What is the difference between normal order evaluation and in order evaluation? (that is: strict and lazy evaluation?). Which programming languages are strict? Which are lazy?

    I believe every one we've studied is strict by default.


    ML or Scheme are both strict by default, although within Scheme working with lazy evaluation is not that hard. All imperative languages seem to be strict as well. Funcional programming languages like Miranda and Haskell are lazy by default. But don't forget the best known 'lazy' language in the world: math.

    Anonymous:

    > But when you need to write a chat-bot, a web-page crawler, a resource-planner, a 3d engine, a spam filter, a speech-recognition filter, a distributed raytracer, a compiler, etc.  you gonna need _formal_ training.     

    Fair enough :)


    I thought so. But it seems here on WTF education itself is considered a WTF by some, which kind of got me started on these little questions.


  • (cs) in reply to mister r
    Anonymous:
    zip:

    mister r:

    Depth-first-search is an _algorithm_ not a design pattern. The design pattern in the case of the sudoku puzzle would _obviously_ be modelling it as a constraint-satisfaction-problem. Any sudoku puzzle can be translated into a set of equality constraints. Just like SEND+MORE=MONEY puzzles, or the 8-queens-problems.

    Design Pattern...You keep using that word. I do not think it means what you think it means.



    When I use the word, I refer to how to abstract away the underlying problems. In other words, the preffered method of slicing a problem into a more general one, and its constants. Like a fold is a generalization of a map. But thats my definition, whats yours' ?

    Design patterns refer to (generally, object-oriented) ways of solving problems, not ways of representing them, which was my complaint with your original post.   Constraint satisfaction is a representation of the problem you are solving, but it does not say anything about how you should minimize the number of unsatisfied constraints. 

     Traditionally design patterns are ways to genericize software engineering problems, not math problems like you are describing here, which is probably why I objected to your usage of the term.  I would have used "problem representation," as you are not "designing" anything by saying "this is a SAT problem!"

     

  • sheryls (unregistered) in reply to LuciferSam

    LuciferSam:

    Obey the fist!

    yay you win at zim! :D

    "THEN I WILL SERVE FOOD WITH MY IRON FIST! And I will work my way up until i rule you all with my iron fist!"

    *is wearing invader zim tee today*

Leave a comment on “Certified Bumblehead”

Log In or post as a guest

Replying to comment #:

« Return to Article