# Code

### Write a Program to Find GCD of Two Numbers

What is GCD (Greatest Common Divisor)? GCD of the two numbers is the largest positive integer that divides both numbers. Characteristics: The GCD of the two numbers is...

### How to Check if a Given Number is Fibonacci Number in Python?

We all know about the Fibonacci series. In this tutorial, instead of printing the Fibonacci sequence, we want to check whether the given number is a Fibonacci number or...

### C++ Program to Find the nth Bit of Number (Bit Masking)

Sometimes interviewers also twist the question and ask you to check if the nth bit is set or not. You have to follow the same approach. Algorithm and approach: Left shift 1...

### Write a Program to Find the Median of Array (by Sorting)

Explanation You will be given a list of numbers. Let's say 7, 8, 4, 5, 2 First, you have to sort the numbers using the swapping methodology. Sorted list: 2, 4, 5, 7,...

### Write a Program to Find the Transpose of a Matrix

Explanation Transposing a matrix is also known as flipping a matrix where rows become columns and columns become rows, In other words, lets M is a matrix and Transpose of...

### Second Largest/Smallest Number in Array in C/C++, Java and Python

In an earlier tutorial, we have seen how to find the smallest or largest number from the integer array. In this tutorial, we are going to find the second smallest number in an...

### Find the Smallest and Largest Number in Array in C/C++, Java and Python

Here is the program to find the smallest and largest number in the array in C/C++, Java and Python. I have also added the comment explaining each line of the code. So the code...

### 7 Amazing Reasons | Why You should Learn Coding

In today’s world when everyone wants everything to be a click away, there’s no skill better than coding that you can learn. Today, coding is linked with everything you can...

### [Solved] Program to Find Pairs that have Desired Sum in Java, Python

Problem Statement: Consider an array of integers that may contain both positive and negative integers, called numbers. Write a program that finds all the pairs of integers whose...