6 Replies - 1669 Views - Last Post: 05 June 2015 - 07:35 PM

#1 Lemur  Icon User is offline

  • Pragmatism over Dogma
  • member icon


Reputation: 1439
  • View blog
  • Posts: 3,609
  • Joined: 28-November 09

5 programming problems every Software Engineer should be able to solve

Posted 08 May 2015 - 10:49 PM

https://blog.svpino....ess-than-1-hour

This has been making the rounds lately. I have various objections with asking questions like this in an interview, but it may be a bit fun to try them for some of you.

Kudos if you can solve #4 without permutations. My (explained) edition is here: https://gist.github....bf03621a278dfb8

So, as to discussion-ability: What do you think of asking these types of questions in interviews, and what are your solutions to the problems?:

Spoiler


Is This A Good Question/Topic? 0
  • +

Replies To: 5 programming problems every Software Engineer should be able to solve

#2 BobRodes  Icon User is offline

  • Lovable Curmudgeon
  • member icon

Reputation: 600
  • View blog
  • Posts: 3,069
  • Joined: 19-May 09

Re: 5 programming problems every Software Engineer should be able to solve

Posted 04 June 2015 - 10:22 AM

I think it's pretty interesting that the guy who wrote this said that any engineer ought to be able to solve all of his problems in an hour, and then found that he had made mistakes in problem 4. In other words, it looks like he didn't solve his own problems in an hour, whether he says so or not.
Was This Post Helpful? 1
  • +
  • -

#3 jon.kiparsky  Icon User is offline

  • Chinga la migra
  • member icon


Reputation: 10720
  • View blog
  • Posts: 18,353
  • Joined: 19-March 11

Re: 5 programming problems every Software Engineer should be able to solve

Posted 04 June 2015 - 12:00 PM

I'm always a little wary of the "you should be able to solve this problem in X time or you're not a real programmer" mindset. I have no problem with asking someone to solve a problem, but I'm more interested in how they go about solving it. And frankly, I'm mostly interested in seeing what people do when they have a problem that they can't solve. After all, that's what they're there for.
Was This Post Helpful? 2
  • +
  • -

#4 BobRodes  Icon User is offline

  • Lovable Curmudgeon
  • member icon

Reputation: 600
  • View blog
  • Posts: 3,069
  • Joined: 19-May 09

Re: 5 programming problems every Software Engineer should be able to solve

Posted 04 June 2015 - 08:41 PM

View Postjon.kiparsky, on 04 June 2015 - 02:00 PM, said:

I'm always a little wary of the "you should be able to solve this problem in X time or you're not a real programmer" mindset. I have no problem with asking someone to solve a problem, but I'm more interested in how they go about solving it. And frankly, I'm mostly interested in seeing what people do when they have a problem that they can't solve. After all, that's what they're there for.
I'm wary of it too. Such a mindset usually has difficulty acknowledging failure.
Was This Post Helpful? 2
  • +
  • -

#5 ishkabible  Icon User is offline

  • spelling expret
  • member icon





Reputation: 1744
  • View blog
  • Posts: 5,896
  • Joined: 03-August 09

Re: 5 programming problems every Software Engineer should be able to solve

Posted 05 June 2015 - 02:28 AM

problem 5 in haskell I think. The answer I got out seems too short to make sense to me personally. I expected a ton of answers back from this but only got 6. Does anyone know the correct answer?
Spoiler

Was This Post Helpful? 0
  • +
  • -

#6 baavgai  Icon User is online

  • Dreaming Coder
  • member icon


Reputation: 6996
  • View blog
  • Posts: 14,635
  • Joined: 16-October 07

Re: 5 programming problems every Software Engineer should be able to solve

Posted 05 June 2015 - 05:52 PM

When I figure out a problem, I'm actually rather slow. I like to roll it around a little. Consider several ways before settling. If under time constraints, I have to force myself not to tweak.

View Postishkabible, on 05 June 2015 - 05:28 AM, said:

problem 5 in haskell I think.


Damn you... You made me look at the thing. Note, this took me well over an hour. Much tweaking. I got more answers than you, I'm afraid.
Spoiler

Was This Post Helpful? 0
  • +
  • -

#7 ishkabible  Icon User is offline

  • spelling expret
  • member icon





Reputation: 1744
  • View blog
  • Posts: 5,896
  • Joined: 03-August 09

Re: 5 programming problems every Software Engineer should be able to solve

Posted 05 June 2015 - 07:35 PM

Ah that is my issue

Spoiler


After "fixing" that issue I still didn't get all the answers that you got. Also my "fix" has well increased the size of my code. I'm stopping with this idea and going to try and find another way.

edit:
change quote to spoiler tags...whoops

This post has been edited by ishkabible: 05 June 2015 - 07:40 PM

Was This Post Helpful? 0
  • +
  • -

Page 1 of 1