Print Nth node of a singly linked list in the reverse manner
You must be able to fetch the nth node in a singly linked list in the reverse manner eg:- if there is a list of 100 nodes and node number 10th is passed, you must be able to return the 10th node from the end of the list.
I am implementing this in C.
I'd like to implement it in C++.
Sure. Go for it 👍
Aditya, were you able to review my reverse link list code
Which one? Did you make a pull request?
Yes of course
Yes. I see. I have merged it 🎉
Oh is it, why didn't I get a mail then?
You should have overlooked. Take a look at the pull request 👍 #518
In which directory should I add my file?
Create a folder n_th_node_linked_list under here and place your code there 👍
Made a PR. Kindly review it. #671 Thanks.
Merged 👍
How about a version of this algorithm (PrintNthToLast) as a templated algorithm in c++?
Aditya, how can I update the git repository , since when I had cloned earlier there was no directory for the nth node directory
I used git pull, but it shows Already up-to-date, but don't see the directory which you created inside Linked_lists. Can I add and commit this in Linked_lists itself.
I would like to do this in c++
I cloned and did a git add of my soruce code in the n_th_node_linked_list and did a commit, however when i try doing a git push it gives the following error;- remote: Permission to OpenGenus/cosmos.git denied to rstalekar. fatal: unable to access 'https://github.com/OpenGenus/cosmos.git/': The requested URL returned error: 403
@rstalekar You need to clone this repository and push in your local work-space 👍
What am I doing wrong here as per you? I did a git clone 'https://github.com/OpenGenus/cosmos.git/ in my home directory Then I navigated to the Linked_lists/ n_th_node_linked_list and then wrote my code and did git add . git commit also went through , only when I do git push I get the above error.