Redis as Cache: How it Works and Why to Use it

7 months ago Lalit Bhagtani 0
Introduction Redis, an open-source, in-memory data structure store, has emerged as a leading caching solution, providing remarkable speed and flexibility. Originally designed as a key-value store, Redis has evolved into a versatile data management system that can be used for a variety of use cases, including caching. Its in-memory nature enables lightning-fast access to data, Read More

Enums in Solidity : Solidity Programming

8 months ago Lalit Bhagtani 0
Introduction In this article, we will explore the concept of enums in solidity programming language, discussing their advantages, disadvantages, and real-world examples of their implementation in decentralized protocols. What are Enums in Solidity ? Enums are a user-defined data type in Solidity that allows developers to declare a finite set of named constants. These constants Read More

Creating Ordered List : Solidity Programming

8 months ago Lalit Bhagtani 0
Introduction When it comes to writing efficient smart contracts in Solidity, understanding data structures plays a crucial role. In this article, we will explore the concept of ordered lists in Solidity and how we can create them using a mapping data structure. We’ll dive into the benefits of using this approach, examine a real-world example Read More

Find Bottom Left Tree Value | Tree Problem | LeetCode 513

4 years ago Lalit Bhagtani 0
Problem Statement You have given a binary tree, write a program to find out the leftmost value in the last row of the tree. Example  Leftmost value in the last row of first binary tree is 2 and of second binary tree is 6. Breadth First Search In Breadth First Traversal, the tree is traversed Read More

Binary Tree Right Side View | Tree Problem | LeetCode 199

4 years ago Lalit Bhagtani 0
Problem Statement Imagine you are standing on the right side of a binary tree, Write a program to return the values of all the nodes that you can see ordered from top to bottom. Example  The right side view of above binary tree shows nodes.  Breadth First Search In Breadth First Read More

Minimum Depth of Binary Tree | Tree Problem | LeetCode 111

4 years ago Lalit Bhagtani 0
Problem Statement You have given a binary tree, write a program to find out its minimum depth. The minimum depth is the number of nodes along the shortest path from the root node of the binary tree to its nearest leaf node. Example  In above binary tree, the shortest path from root node to its Read More

Insert into a Binary Search Tree | Tree Problem | LeetCode 701

4 years ago Lalit Bhagtani 0
Problem Statement You have given a binary search tree and a value V, insert the value V into the binary search tree and return the root node of the modified BST. It is guaranteed that the value V does not exist in the BST. Example  Inserting 7 into above binary search tree. Solution To solve Read More