Introduction
This is the first article in the Tree Traversals - Online Classes.
To read more about the previous article, please check the topic Hierarchical Datastructure – Binary Tree Implementation. To get updates on the other articles in the series, please use the Subscribe feature on the right panel.
Purpose of article
This article will take over from where we wrapped up in the last article, It will define the remaining two methods elements() and positions() of the Tree ADT for LinkedBinaryTree. And we will also discuss the Tree traversals and code for the Binary Tree. We will finish...

Read More
# online classes

## Interview Question – Static variables

Introduction
This question was asked in a recent java interview in Goldman Sachs, this isn't complicated but candidates might get confused solving it. This is about static blocks and static variables initialization, so I publish this article under the heading Interview Question - Static variables. To get updates on the other articles in the series, please use the Subscribe feature on the right panel.
Problem Statement
What would be the result when the below code is executed?
[crayon-5977021a4d7f8285283564/]
Solution
What is the approach for solving this question?
Remember your b...

Read More
## Hierarchical Datastructure – Binary Tree Implementation

Introduction
This is the third article in the series of non-linear data structures, to read more about the previous article, please check the topic HIERARCHICAL DATA STRUCTURE – TREE ADT. People might feel that the pace with which we are progressing is too slow, but I woul dlike to assure you that these are the articles which are the roots of the non-linear data structures, if we do not spend enough time on these, we might face bigger challenegs later. To get updates on the other articles in the series, please use the Subscribe feature on the right panel.
Purpose of article
This article wil...

Read More
## Hierarchical Data Structure – Tree ADT

Introduction
This is the second article in the series of non-linear data structures, to read more about the previous article, please check the topic HIERARCHICAL DATASTRUCTURE – DETAILED DISCUSSION. To get updates on the other articles in the series, please use the Subscribe feature on the right panel.
Purpose of article
This article will mostly focus on the coding aspect of what we learnt in the first article, it will also make us eligible to go hand in hand with the codes and we can simultaneously test what all we are learning. We will define all the structures which will end up creating ...

Read More
## Hierarchical Datastructure – detailed discussion

Introduction
I was planning to write an article on recursion before writing this article, but I got few requests to write about Tree Data Structure. So here I go, please treat this post as the starting of a series of articles based on Tree Data Structure in general, this might extend to a list of ten full length articles where we will learn in detail about Tree Data Structure, Types of Trees, How to store Trees in Memory, Variations of Trees, Tree Traversals, N-ary Trees and few real life examples of trees.
Purpose of the Article
This is just an introduction on Tree data structure, we will ...

Read More
## Hashing in detail – Part Three

Introduction
This is the third post in Hashing - Online Classes.
Please check the previous articles Hashing in detail – Part One and Hashing in detail – Part Two. In the first two articles we established a better understanding of the data structure which can be used to store objects using hashing, we also learnt about handling collisions and chaining. In "Hashing in detail - Part Three" post we will extend the discussion and wrap up basic concepts of hashing.
Purpose of the article
In the article Hashing in detail - Part 3 we will learn another collision resolution method called Open...

Read More
## Interview Question – Pirate and the Gold Chest

Interview Question – Pirate and the Gold Chest :
Once there were five pirates, each of them equally rational, intelligent and greedy. The pirates can be numbered as P1, P2, P3, P4 and P5 such that P5 has 1 years of service experience, P4 has 2 years of experience, P3, P2 and P1 has 3, 4 and 5 years of experience respectively.
One day they find a chest of 100 gold coins and they decided to divide it among themselves. Everyone being equally greedy wanted maximum profit, so they decided for the following solution:
1) Each pirate will get a chance to propose a distribution rule, and then a ...

Read More