- Trending Categories
- Data Structure
- Networking
- RDBMS
- Operating System
- Java
- MS Excel
- iOS
- HTML
- CSS
- Android
- Python
- C Programming
- C++
- C#
- MongoDB
- MySQL
- Javascript
- PHP
- Physics
- Chemistry
- Biology
- Mathematics
- English
- Economics
- Psychology
- Social Studies
- Fashion Studies
- Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Sudhir sharma has Published 1206 Articles
sudhir sharma
118 Views
In this problem, we are given a number n and we have to print all N digit patterns formed by pressing the mobile keypad button. While pressing the buttons, we can press only nearby buttons of the current button i.e. only keys left, right, up, down can be pressed.Let’s see ... Read More
sudhir sharma
345 Views
In this problem, we are given two numbers n and sum. We have to print all n digit numbers whose sum is equal to the sum. In this problem, numbers with leading 0’s are not considered.Let’s take an example to understand the problem, Input: n = 2 , sum = ... Read More
sudhir sharma
167 Views
In this problem, we are given an integer n, and we have to print all n-digit numbers such that the absolute difference between the sum of digit of the number at even and odd places is 1. While creating the numbers leading 0’s are not considered.The absolute difference is the ... Read More
sudhir sharma
264 Views
In this problem, we are given a number N and we have to print all n-digit numbers whose digits are strickly increasing from MSB to LSB i.e. the number at LSB (left) should be smaller than the number at right.Let’s take an example to understand the problem −Input − n ... Read More
sudhir sharma
399 Views
In this problem, we are given a binary tree, a target node and an integer K. We have to print all the nodes of the tree that are at a distance K from the target node.Binary Tree is a special tree whose each node has at max two nodes (one/two/none).Let’s ... Read More
sudhir sharma
142 Views
In this problem, we are given a binary tree and two levels in the tree (upper and lower) and we have to print all nodes between upper and lower levels of the tree.The binary tree is a special tree whose each node has at max two nodes (one/two/none).Let’s take an ... Read More
sudhir sharma
103 Views
In this problem, we are given a binary tree and an integer K and we have to print all nodes of the binary tree that have K leaves in their child subtree.The binary tree is a special tree whose each node has at max two nodes (one/two/none).The leaf node of ... Read More
sudhir sharma
177 Views
In this problem, we are given a Min Heap and a value x and we have to print all nodes less than x.Min heap is a special type of binary tree in which every node has a value less than the node value of its child node.Let’s take an example ... Read More
sudhir sharma
144 Views
In this problem, we are given a binary tree and a number K. We have to print all nodes of the tree that are at k distance from the leaf node.Binary Tree is a special tree whose each node has at max two nodes (one/two/none).The leaf node of a binary ... Read More
sudhir sharma
113 Views
In this problem, we are given an integer N and we have printed all the number less than N with at-most 2 unique digits i.e. maximum 2 different digits can be used to create the number.Let’s take an example to understand the problem −Input: N = 17 Output: 1 2 ... Read More