- 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
Hafeezul Kareem has Published 344 Articles
Hafeezul Kareem
295 Views
In this tutorial, we are going to write a program that finds a number such that its modulus with each array element is same. Let's see an example.Input − arr = {10, 4, 2}Output − 1 2If there are two numbers x, y and x > y, assume that x ... Read More
Hafeezul Kareem
64 Views
In this tutorial, we are going to write a program that calculates ∆ X value that satisfies the given equation. The equation is (a + ∆ X)/(b + ∆ X) = c/d.Here, we need a little bit of math to solve the equation. And it's straightforward. Cross multiply and take ... Read More
Hafeezul Kareem
58 Views
In this tutorial, we are going to find the zeroes count that need to be flipped to get maximum number of consecutive 1's in the array.We are going to use the sliding window approach to solve the problem. Let's see the steps to solve the problem.Initialize the array and max ... Read More
Hafeezul Kareem
628 Views
In this tutorial, we are going to write a program that finds the election winner. We will have an array of votes that each candidate got in the election. Let's see an example.Input {"A", "B", "C", "B", "A", "C", "D", "D", "A", "B", "D", "B", "A", "C", "D"}Output AHere, A and B ... Read More
Hafeezul Kareem
403 Views
In this tutorial, we are going to write a program that find the number of ways a integer can be expressed as sum of given n-th power of unique numbers.We have two integers number and power. And we need to find in how many ways can we represent the given ... Read More
Hafeezul Kareem
87 Views
In this tutorial, we are going to learn how to find the unique pairs that are less than the given number n.Let's see the steps to solve the problem.Initialize the number.Iterate from i = 1 to i < n.Iterate from j = i + 1 to j < n.Print the ... Read More
Hafeezul Kareem
575 Views
In this tutorial, we are going to learn how to write a program for union and intersection of two unsorted arrays. Let's see an example.Input arr_one = [1, 2, 3, 4, 5] arr_two = [3, 4, 5, 6, 7]Output union: 1 2 3 4 5 6 7 intersection: 3 4 5Let's see ... Read More
Hafeezul Kareem
403 Views
In this tutorial, we are going to learn how to find distinct characters from the given two strings. Let's see an example.Input string_one = "tutorialspoint" string_two = "tutorialsworld"Outputd n p wWe are going to use hashing to solve the problem. It's more efficient than writing two nested loopLet's see the steps ... Read More
Hafeezul Kareem
180 Views
In this tutorial, we are going to write a program to find two numbers where x + y = n and x * y = n. Sometimes it's not possible to find those types of numbers. We'll print None if there are no such numbers. Let's get started.The given numbers are ... Read More
Hafeezul Kareem
279 Views
In this tutorial, we are going to write a program the find two distinct prime numbers with the given product. Let's see some examples.Input − 21Output − 3 7Here, we need to have all the prime numbers that are less than the given product. Once we have those prime numbers, ... Read More