Live data from Hacker News

programming challenge

glyphtree.com

1–10 of 43 posts

Re: programming challenge

#4
post #3

View source on the home page is interesting too.

I was kind of hoping it would explain what Glyphtree is, but it's a riddle/poem.

It has me wondering how 'loser' is defined and if a person can be their own 'friend' ... (read their riddle poem if that makes no sense to you).

Re: programming challenge

#5
post #2

This looks like a really cool challenge. Reminds me a bit of the knapsack problem ( http://en.wikipedia.org/wiki/Backpack_problem ) But something tells me the solution is going to be a lot less simple though.

If you treated this as a variant on the backpack problem, you run into trouble as you can't properly memoize or use dynamic programming. You use 'timesteps' as the size of the 'knapsack' since the number of balls is unbounded. At each timestep, you cannot determine the the optimal solution to the subproblem and you'd have to save every possible ball combination.

TL;DR - It gets to be a pretty messy/bad backpack and should probably be solved another way

Re: programming challenge

#7
The solution given is incorrect. It yields 29 white balls, while the following yields 35.

  1 jar1:2
  2 
  3 jar2:3
  4 
  5 
  6 jar1:2 jar2:4
  7 
  8 
  9 jar2:6
  10 
  11 
  12 jar1:11 jar2:3
  13 
  14 
  15

Re: programming challenge

#8
If you run whois and check linkedin, you can figure out where the author most likely works and what sort of things they do... No names since he probably doesn't want to be googleable.

Re: programming challenge

#9
post #8

If you run whois and check linkedin, you can figure out where the author most likely works and what sort of things they do... No names since he probably doesn't want to be googleable.

You can tell the author is the user who submitted this to hacker news.

Re: programming challenge

#10
post #7

The solution given is incorrect. It yields 29 white balls, while the following yields 35. 1 jar1:2 2 3 jar2:3 4 5 6 jar1:2 jar2:4 7 8 9 jar2:6 10 11 12 jar1:11 jar2:3 13 14 15

is there a need for jar2:3 at line 12 ?
Post reply on HN