A challenge with a $5 bitcoin prize
What up replers!
I've got an algorithms problem for you, where you're trying to find the longest pay it forward chain of gifts.
Check the details there👆 - and comment down if you have any questions.
The first to get a solution that works (only js please!) gets a $5 bitcoin prize - include your BTC address with your solution.
Edit: @ammarbinfaisal won 🏆
@MrEconomical oof that was a stupid mistake, added quotes.
by pay it forward chain, I mean where person B is gifted a book by Person A, and then gifts a book to person C, after which Person C gifts a book to Person D and so on.
In this case, the chain would be
A => B => C => D.
One person can appear multiple times in a chain.