Hacker News new | ask | show | jobs
by siganakis 5227 days ago
My bad, I got that wrong.

The translated array should be:

1 0 2 3 0 3.

I am correcting the article now. For a non-rushed, accurate description please look at:

http://www.alexbowe.com/wavelet-trees

Edit: Got it wrong again... I guess this is why we have computers and debuggers!

1 comments

Looks like you still have some bugs:

  rewritten data: 1 0 2 3 0 3
  first row     : 0 0 1 1 0 1
  group a       : 1 0     1
  group b       :     2 2   3
Group a and group b don't seem to match up with the data. Or I've misunderstood something.
I'm in the same boat. siganakis?