Results 1 to 1 of 1
- 09-25-2012, 04:07 AM #1
Member
- Join Date
- Aug 2012
- Posts
- 11
- Rep Power
- 0
Linked List Class Cons, is this possible to turn into a doubly linked list?
So I have been trying out a Cons style linked list with only two pointers, one pointing at the first element of the list, and then the second pointing to the entire remainder. Is there a way I could turn this into a doubly linked list? Preferably without changing the current attributes, perhaps just adding more.
Java Code:class Cons { Object car; Cons cdr; Cons(Oject first, Cons rest) { car = first; cdr = rest; } }Last edited by Googol; 09-25-2012 at 04:26 AM.
Similar Threads
-
Doubly Linked List removing help?
By Bungkai in forum New To JavaReplies: 0Last Post: 12-02-2011, 06:58 AM -
Doubly-Linked list
By swp in forum New To JavaReplies: 3Last Post: 10-11-2011, 03:27 PM -
Sorted Doubly linked List
By student2889 in forum New To JavaReplies: 1Last Post: 10-14-2010, 10:05 AM -
Doubly Linked List
By matin1234 in forum New To JavaReplies: 0Last Post: 06-02-2010, 05:58 AM -
Help with Doubly linked list
By Dr Gonzo in forum New To JavaReplies: 5Last Post: 12-06-2008, 07:45 AM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks