
This course includes our updated coding exercises so you can practice your skills as you learn.
See a demo
GitHub Account: https://github.com/reedlearningacademy/data-structures
Arrays are a fundamental data structure we need to know and understand when programming. We will go over what you need to know such as how to declare and initialize an array, indices, accessing and iterating over arrays.
You will be able to declare and initialize arrays, as well as accessing them and iterating over an array through Java code. We will also go over an ArraysIndexOutOfBoundsException, which is important to understand.
2D Arrays are useful since data is naturally organized in rows and columns. Spreadsheets and Relational Databases are great examples of this. In this section, we will understand how to declare and initialize 2D arrays, and how to access and iterate over them.
You will be able to declare and initialize 2D Arrays, as well as accessing them and iterating over a 2D Array through Java code. This is similar to a 2D Array, however it can be somewhat tricky when iterating with a nested loop. Just be careful and you will understand how it works after this section.
This is a video answer to the coding exercise. Even if you weren't able to complete it, that's okay, just learn something new here and it may be helpful in the future!
The Singly Linked List is another common data structure that we should understand. You will know it's structure, how nodes are linked to each other, and how to insert and remove.
You will understand how to code a Singly Linked List in Java. We create a few methods including insertion and deletion, as well as some auxiliary methods like retrieving the first element in the list.
A Circularly Linked List is similar to a Singly Linked List except the tail node doesn't have a null as its next pointer, instead it wraps around to the head node. You will understand how a Circularly Linked List works.
You will understand how to code a Circularly Linked List in Java. Most everything is the same, except we introduce a new method called rotate(), which will allow the tail node to point its next reference to the head.
The huge difference between this and the other Linked Lists, is that we have a reference on each node to its previous reference. This allows a traversal forwards and backwards, which wasn't possible in the other Linked Lists. You will understand all of this and how sentinel nodes work in this lecture.
You will understand how to code a Doubly Linked List in Java. The hard part here is when inserting and removing how to change the references on the nodes around them.
In this lecture, I will explain what a Stack is and the two common operations, push and pop.
Here we code a Stack using the array implementation. At the end, the code will be tested.
You will understand how a Queue works in this lecture.
You will be able to code a Queue in this lecture.
You will understand how a Deque works in this lecture. Don't confuse this with the method 'Dequeue'. Deque is pronounced like 'Deck'.
You will be able to code a Deque in this lecture.
You will understand the basic tree structure as it's very important since many other data structures will use a variation of a tree.
You will understand the vocabulary of a tree. Remember, when you are talking about a data structure or a programming language, it's always good to talk within the context of it. This lecture will help you understand the context of a tree.
A Binary Tree is a variation of a General Tree where each node can only have at most two children nodes. We are getting closer to understanding the Binary Search Tree.
You will understand the importance of the Binary Search Tree. Here you will know how operations such as insertion work in a Binary Search Tree. It's a good idea to take your time through this lecture as other data structures we will learn derive from this.
You will understand how to traverse a Tree. This is important for a couple of reasons, one being we may need to do something at the nodes, but we can't just go to any node we want. We will need to start at the root and work our way around. This can be good for math expressions for example.
You will learn how to implement a Node class and the insertion method for a Binary Search Tree in Java.
You will learn how to implement the deletion method for a Binary Search Tree in Java.
You will learn how to code the Height and Depth of a Binary Search Tree.
You will learn how to implement the tree traversals we discussed earlier for a Binary Search Tree in Java.
We will test the code we just developed.
In this lecture, I will explain what a Heap is and what downheap and upheap are. We will specifically go over a MinHeap, where the minimum value is always at the root of the tree. Then we will go over an array implementation of a heap.
We will go over an example of a Heap by a series of insertions and removals. Remember when removing from a MinHeap tree, we always remove the smallest value, which is always the root of the tree, or index zero.
You will learn how to implement a MinHeap class in Java.
We will now test our code!
In this lecture, I will explain what a Skip List is. We will go over how it's formed, the "sentinel nodes", insertion, searching, and deletion.
Here we go over the Skip List Searching and a little introduction to coding it.
We go over how to code for a Skip List insertion operation.
We go over how to code a Skip List deletion operation.
Now we have to test our code!
In this course we'll go over Data Structures for Java with explanations, examples, and then finally coding them. We will start with simple Data Structures such as Stacks and Queues, and gradually move to more advanced topics such as Splay Trees and AVL Trees to Graphs.
We will help you from a beginner understanding of how these Data Structures work or if you have some knowledge already, this course will supplement and even give you better ideas through examples and a structured presentation. If you need help with Interviews with more knowledge of Data Structures, this course will help.
There are some coding exercises which are derived from Interview Questions and help understanding how Data Structures can be used to solve problems.
We provide examples for Tree Data Structures as they can be tricky, for instance with AVL Trees. Learning Balanceable Tree structures can be confusing, but we will alleviate any confusion with examples and organized presentations.
Here is what you will be learning:
Arrays
2D Arrays
Stacks
Queues (Deques, Circular)
Linked Lists (Singly, Doubly and Circularly)
Binary Trees
Binary Search Trees
Tree Traversals
Heap (Min-Heap)
Skip List
AVL Trees
Splay Trees
Red-Black Trees
Graphs
By the end of this course, you will understand how these Data Structures work and will have running code to test them!