Thread: what is an iterator

  1. #1
    Registered User
    Join Date
    Nov 2011

    what is an iterator

    What is an iterator in a double linked list and what is it used for

  2. #2
    spurious conceit MK27's Avatar
    Join Date
    Jul 2008
    segmentation fault
    "Iterator" is more of a C++ or Java term. Applying the concept in C, it would just be a pointer or function used to walk a list from head to tail.

    The traditional use of i as the control variable in for() loops which iterate through an array stands for either index or iterator -- same principle.
    Last edited by MK27; 11-30-2011 at 06:25 AM.
    C programming resources:
    GNU C Function and Macro Index -- glibc reference manual
    The C Book -- nice online learner guide
    Current ISO draft standard
    CCAN -- new CPAN like open source library repository
    3 (different) GNU debugger tutorials: #1 -- #2 -- #3
    cpwiki -- our wiki on sourceforge

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Iterator
    By MarkZWEERS in forum C++ Programming
    Replies: 19
    Last Post: 05-19-2008, 11:16 PM
  2. Connecting input iterator to output iterator
    By QuestionC in forum C++ Programming
    Replies: 2
    Last Post: 04-10-2007, 02:18 AM
  3. std::map::iterator
    By Magos in forum C++ Programming
    Replies: 2
    Last Post: 02-03-2006, 07:47 PM
  4. Do we really need iterator?
    By Antigloss in forum C++ Programming
    Replies: 3
    Last Post: 06-13-2005, 10:59 AM

Tags for this Thread