This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes how to do link list in java? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "how to do link list in java?" Watch "how to do link list in java?" New topic
Author

how to do link list in java?

max soyosa
Greenhorn

Joined: Feb 25, 2010
Posts: 24
hi to all!
can anyone help me or teach me on how to do linklist in java?

please help!
Vijitha Kumara
Bartender

Joined: Mar 24, 2008
Posts: 3816

max soyosa wrote:can anyone help me or teach me on how to do linklist in java?

Do you need an existing implementation for LinkedList (infact there's a one with the name itself) in Java or need to implement a one using Java?
And, please CarefullyChooseOneForum when posting. This forum is for questions specific to JDBC.


SCJP 5 | SCWCD 5
[How to ask questions] [Twitter]
Devaka Cooray
ExamLab Creator
Saloon Keeper

Joined: Jul 29, 2008
Posts: 3011
    
  34

Please tell more details on what you are finding for.
Moving to Beginning Java forum.


Founder of ExamLab and Systemup
See how I can help you to become an awesome programmer
Campbell Ritchie
Sheriff

Joined: Oct 13, 2005
Posts: 37890
    
  22
Start with a singly linked list. Each node has a link to the next node, and the last node keeps a null in that reference. You need recursive methods which look for the next node, and each node has a value of some sort attached as its reference.
Vineet Kakati
Greenhorn

Joined: May 03, 2010
Posts: 21
create a class Node having instance variables data and p;
the variable data stores data.
the variable p is of type Node which points to another node;

create a linked list by creating objects of class node and link them together by using variable p for each node;
p for last node should be null;
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: how to do link list in java?
 
Similar Threads
jms
A basic synchronization question
mini project
Special Characters
Ascii to binary and binary to ascii