Weekend Programming Challenge – Week #50 solutions


Image

We got 8 solutions this weekend:

  • C++ x3
  • Python x3
  • C# x1
  • Pascal x1

you can enjoy them at GitHub.

3 Comments (+add yours?)

  1. kantal
    Apr 15, 2014 @ 21:05:48

    Some “reversed” the problem🙂
    From the real solutions, my favourite is the #8.

    Reply

  2. Flobber
    Apr 16, 2014 @ 04:26:06

    What’s a little bit sad is that among those that solved the problem, only one gave an O(n) solution and another one an O(n*log(n)). All others did the dumb O(n^2) search.

    O(log(n)) should be possible!

    Reply

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: