10 TIPs - To Become a Good Developer/Programmer
Why Join
Become a member
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
C# Corner Home
Technologies
Monthly Leaders
ASK A QUESTION
Forum guidelines
Connie Le
2.1k
2
299
Reverse linked list
Mar 4 2018 1:44 PM
Hi everyone,
Apologies for this painfully simple question, but I just had a question asking to reverse elements in a linked list based on the code that they provided. I have some experience in linked lists, but I am not too familiar with the syntax in C#.
Here's the code they provided:
public static void Reverse(List input) {
[enter code here]
}
public class List {
public Node Head { get; set;}
}
public class Node {
public object Value { get; set; }
public Node Next { get; set; }
}
How would one write code to reverse this particular list? This is not a question for an assignment, but I would like to make sure I understand the concepts correctly. Thank you very much for your time.
Reply
Answers (
1
)
how to convert gridview textbox value into integer format
filling listCheckBox with table data