Height of a Binary Tree: Recursion Unrolled & Explained

— tags: >- development, C++, tree, height, programming, recursion, internals, complete flow categories: development — Height of a Binary Tree is the longest path in the tree. Code int getHeight(node *root) { if (root == NULL) { return -1; } int leftHeight = getHeight(root->left); int rightHeight = getHeight(root->right); return (max(leftHeight, rightHeight) + 1); } Suppose … More Height of a Binary Tree: Recursion Unrolled & Explained

Go Runtime Scheduler Design Internals

Concurrency is one of the most exciting features of Go language. A single threaded program runs serially, but if you have tasks that can run concurrently, you create threads for such tasks. Threads execute independently and progress concurrently. Go supports creation of thousands of threads in an application!! How is it possible? It’s Go’s runtime. … More Go Runtime Scheduler Design Internals