___  ___    _ _    _  _ _____   _____
 / __|/ _ \  | | |  | || |_ _\ \ / / __|
| (_ | (_) | |_  _| | __ || | \ V /| _|
 \___|\___/    |_|  |_||_|___| \_/ |___|

 --- A GOPHER-LIKE INTERFACE FOR HIVE BLOCKCHAIN ---

Coding challenge #2 - Win SBD if you solve the problem!

BY: @armandocat | CREATED: Sept. 15, 2017, 7:15 a.m. | VOTES: 37 | PAYOUT: $24.56 | [ VOTE ]

This is my second contest about coding problems. I find coding problems very interesting and I really enjoy solving them, so I thought: I must not be the only one!

So here I am, writing you some of the problems I found myself working on in job interviews, or competitions I took part in the past.
I hope you enjoy it at much as I do.

https://steemitimages.com/DQmQGxeECpik7rVwtMCWndk8cKE4QEemqjRSSKk5NoTn2q8/question-mark-2123968_640.jpg

This problem is similar to that of last week, but in some way trickier.
Have fun!

Contest #2

In a Linked list, each node has a value and a next node.
Given a Linked list:

1) Write a function that reverse the linked list, using a recursive algorithm.
2) Write a function that reverse the linked list, using a iterative algorithm.
- For instance: given A -> B -> C it returns C -> B ->A

You don't have to clone the nodes, you must just work on their next properties.

The preferred language to use this time is javascript, but you can also use other languages as well. You will need to translate the starting code to the language of your choice.

Rules

Rewards

The liquid reward of this post will be divided between the working solution submitted in this way:
* The most time- and space-efficient, well-written solution will get 50% of the liquid reward of this post
* The second will get 25%
* The third will get 12.5%
* ...
* Well, let's say that if you end up in nth position, you will get 1/2^n%
* If two or more solutions are considered a tie, the time the solution is submitted decide how wins (the first solution submitted wins). Or I can decide to split the rewards equally, for instance if two contestant are considered winners, I may sum the 1st and 2nd price and divide the 75% of the liquid reward between the two.

You have 7 days to submit your answer!
Good luck!

Armando 🐾

TAGS: [ #contest ] [ #coding ] [ #programming ] [ #challenge ] [ #steemstem ]

Replies

@rudel | Sept. 15, 2017, 7:17 a.m. | Votes: 0 | [ VOTE ]

congrats to the winners

@hendrikcrause | Sept. 15, 2017, 9:16 a.m. | Votes: 0 | [ VOTE ]

Yay, another coding challenge. Hope you don't mind that I entered again. 🙂

@armandocat | Sept. 15, 2017, 9:48 a.m. | Votes: 1 | [ VOTE ]

You are more than welcome ;)

@dawnasheelagh | Sept. 15, 2017, 10:29 a.m. | Votes: 0 | [ VOTE ]

@armandocat Your generate up is spectacular. Mad regard for sticking as a result of many of the hardships, Many of us would've Give up A great deal before. Upvoted.

@surfyogi | Sept. 19, 2017, 12:24 a.m. | Votes: 0 | [ VOTE ]

I am a bot!

@pps | Sept. 15, 2017, 4:31 p.m. | Votes: 0 | [ VOTE ]

Solution Submitted

@jjb777 | Sept. 15, 2017, 6:21 p.m. | Votes: 0 | [ VOTE ]

Submitted

@chasmic-cosm | Sept. 16, 2017, 6:14 p.m. | Votes: 0 | [ VOTE ]

Cool another coding challenge!

[ BACK TO TRENDING ] [ BACK TO MENU ]
CMD>