Linked List Help please

From: Shane (
Date: 08/11/04

Date: 10 Aug 2004 23:16:15 -0700

Thanks in advance for the help.

I'm new to the STL and havig a bit of trouble figuring out the whole
iterator thing. I am using the <list> template and I can insert
elements into the list just fine. I just can't get them out. It's
like the roach motel! (uh, you can go in, but don't come out...

Actually, I have been able to get some help from

I can get the forst element or the last, but I can't find one
in-between or pick one out like you would in an array by referencing
the element number.

Can someone give me a hand or point me to a tutorial? I have found a
lot of tutorials, but all of them use ints as elements in the list,
and I need to store objects.


list<People::People> PP;

//person is a People


Now the person has been added to the linked list. I can get it out by

person2 = PP.front();
cout << person2.getName();

but this is only if the person is at the front of the linked list.

Any suggestions? I know it's all there at in black and white. I just
don't understand it.


Relevant Pages

  • Re: CSS side menu and IE -- both styles posted online now
    ... Peter Mount wrote: ... This site is good as it has tutorials from professional web developers. ... I had a look at it in IE6 and I see now that it does look bad as you say. ... found a great template website,, and found an open source template I really liked that even came in 2 versions. ...
  • Re: blank fields - creating template in Word for Mac
    ... especially the forms tutorials by Dian Chapman that this article links to. ... Suzanne S. Barnhill ... Microsoft MVP (Word) ... template text document with blank fields that can be filled in by the ...
  • Generating templates - CS file not appearing
    ... I've followed the tutorials on template ... generation but for some reason, ... Google provided no help as far ...
  • Re: "About page" template
    ... copyright and found under help menus) from a template. ... I've looked for new file/project types in visual studio 2008 and searched ... the Internet for tutorials and temples for about pages without success. ... Windows Form ...
  • Tutorials for Conditional Macro
    ... Anybody have any good tutorials for using the "Condition" portion of the ... I'm having some trouble figuring out what types of things I ...