List of Figures


Chapter 1: Memory, Abstract Data Types, and Addresses

Figure 1-1: A bus connects the CPU, main memory, persistent storage, and other devices.
Figure 1-2: A byte abstract data type in Java reserves 8 bits of main memory.
Figure 1-3: A short abstract data type in Java reserves 16 bits of main memory.
Figure 1-4: An int abstract data type in Java reserves 32 bits of main memory.
Figure 1-5: A long abstract data type in Java reserves 64 bits of main memory.
Figure 1-6: A float abstract data type in Java reserves 32 bits of main memory.
Figure 1-7: A double abstract data type in Java reserves 64 bits of main memory.
Figure 1-8: A char abstract data type in Java reserves 16 bits of main memory.
Figure 1-9: A boolean abstract data type in Java reserves 1 bit of main memory.
Figure 1-10: The memory address of the first byte is used to reference all bytes reserved for an abstract data type.

Chapter 2: The Point About Variables and Pointers

Figure 2-1: Memory for elements of a structure are placed in sequential memory locations when an instance of the structure is declared.
Figure 2-2: Memory for attributes of a class are placed in sequential memory locations when an instance of the class is declared.
Figure 2-3: Memory allocated when two pointers and two variables are declared
Figure 2-4: Memory allocated after pointers are assigned memory addresses
Figure 2-5: Memory allocated after values are assigned to variables
Figure 2-6: Memory allocated after the value of the ptGrade is copied to ptOldGrade.
Figure 2-7: Memory allocated after the contents of the memory address pointed to by ptGrade is copied to the oldGrade variable.
Figure 2-8: Memory allocation before incrementing ptStudentNumber1
Figure 2-9: Memory allocation after incrementing ptStudentNumber1
Figure 2-10: The pointer to a pointer variable is assigned the memory address of the ptInitial pointer.
Figure 2-11: Two memory addresses are referenced when using a pointer to a pointer to display a value on the screen.

Chapter 3: What Is an Array?

Figure 3-1: Elements of an array are stored sequentially in memory.
Figure 3-2: A two-dimensional array is a multidimensional array consisting of two arrays.
Figure 3-3: All three grades can be stored in a multidimensional array.
Figure 3-4: Elements of a multidimensional array are stored sequentially in memory.
Figure 3-5: Braces define sets of values to be assigned to array elements (the top example is C and C++ and the bottom example is Java).
Figure 3-6: Display the contents of array elements by referencing the index of both sets of array elements.
Figure 3-7: Use the array name as a pointer to the first array element.
Figure 3-8: Memory allocation after the pointer is assigned the address of the first array element
Figure 3-9: Using the content pointed to by an array of pointers
Figure 3-10: An array of pointers to pointers reorganizes names without changing the order of the array that contains the names .
Figure 3-11: Using a pointer array and an array of pointers to pointers to display the contents of an array of strings

Chapter 4: Stacks Using an Array

Figure 4-1: A stack and an array are two different things: an array stores values in memory; a stack tracks which of the array elements is at the top of the stack.
Figure 4-2: The new value is assigned to the next array element and its index becomes the top of the stack.
Figure 4-3: All values move toward the top of the stack when the top item is popped off the stack.

Chapter 5: Queues Using an Array

Figure 5-1: The queue is different from the array used to store data that appears in the queue.
Figure 5-2: The enqueue process places a new value at the back of the queue.
Figure 5-3: The dequeue process removes an item from the front of a queue.
Figure 5-4: The isFull() member function determines if there is room to place another item on the back of the queue.
Figure 5-5: The isEmpty() member function determines if the queue contains any values.
Figure 5-6: Heres the queue and the array after the last call to the enqueue() member function is made.

Chapter 6: What Is a Linked List?

Figure 6-1: Students are seated in a classroom in random order.
Figure 6-2: A node contains reference to the next node and the previous node in the linked list and contains data that is associated with the current node.
Figure 6-3: A doubly linked list contains next and previous members , and a single linked list contains only a next member.
Figure 6-4: The appendNode() member function changes what nodes are pointed to in the linked list.
Figure 6-5: The previous member of each node transverses the linked list.
Figure 6-6: The destroyList() member function removes nodes beginning with the last node on the linked list and works its way to the beginning of the linked list.

Chapter 7: Stacks Using Linked Lists

Figure 7-1: A node contains references to the previous node and the next node in the linked list and contains data that is associated with the current node.
Figure 7-2: The pop() member function removes the node at the top of the stack, which is the node at the front of the linked list.
Figure 7-3: Before the pop() member function is called, there are three nodes on the stack. Two nodes remain after pop() is called.

Chapter 8: Queues Using Linked Lists

Figure 8-1: Each node points to the previous node and the next node.
Figure 8-2: A new node is added to the queue at the back of the linked list.
Figure 8-3: Node 1 is removed from the back of the queue by the dequeue() member function.
Figure 8-4: The queue after all three values are placed on the queue.
Figure 8-5: The queue after the dequeue() member function is called
Figure 8-6: The queue after all values are placed on the queue

Chapter 9: Stacks and Queues: Insert, Delete, Peek, Find

Figure 9-1: A linked list containing five nodes with each node identified by an index value
Figure 9-2: The linked list after NodeC is removed
Figure 9-3: A new node called NodeN is placed in index position 2 within the linked list.
Figure 9-4: The top is the linked list before the node is removed, the middle is after removeNodeAt(3) is called, and the bottom is after deleteNode(2) is called.
Figure 9-5: The linked list after the insertNodeAt(1) is called

Chapter 10: What Is a Tree?

Figure 10-1: A binary tree is a tree where each stem has no more than two branches.
Figure 10-2: A binary tree is comprised of several nodes, each of which are related to other nodes on the tree.
Figure 10-3: The number of levels in a tree defines a trees depth, and the number of nodes defines the size of the tree
Figure 10-4: The left child node is always less than the parent node, and the right child node is always greater than the parent node.
Figure 10-5: Each node has an index and a value; the index uniquely identifies the node and retrieves the value of a node.
Figure 10-6: Regardless of the order in which data is added to the tree, the left child node is less than the parent node and the right child node is greater than the parent node.
Figure 10-7: The left child node is removed from the tree; the tree still has a depth of two levels.

Chapter 11: What Is a Hashtable?

Figure 11-1: The hashtable is an array whose elements point to user -defined structures that contain data.
Figure 11-2: A linked list connects user-defined structures whose keys hash to the same hash value.
Figure 11-3: The constructor declares an array of pointers where each element of the array points to an instance of the metadata structure.
Figure 11-4: Heres what happens after the first entry is placed on the hashtable by calling the put() function.
Figure 11-5: The hashtable created after the put() function is called for the last time



Data Structures Demystified
Data Structures Demystified (Demystified)
ISBN: 0072253592
EAN: 2147483647
Year: 2006
Pages: 90

Similar book on Amazon

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net