## Minimize cost to Swap two given Arrays

Given two arrays A[] and B[] both of size N consisting of distinct elements, the task is to find the minimum cost to swap two… Read More »

- Write an Article
- Courses @ GeeksforGeeks
- Internships @ GeeksforGeeks
- Coding Practice
- How to write an Interview Experience?
- Must Do Coding Questions Company-wise
- Must Do Coding Questions Topic-wise
- Basic
- Easy
- Medium
- Hard
- Expert
- Step by Step Preparation
- Company Preparation
- Top Topics
- Company Specific Practice
- Software Design Patterns
- Placements Preparation Course
- Interview Corner
- Recent Interview Experiences
- GQ Home Page
- Quiz Corner
- LMNs
- What's New?
- Leaderboard !!
- Topic-wise Practice
- Subjective Problems
- Difficulty Level - School
- Difficulty Level - Basic
- Difficulty Level - Easy
- Difficulty Level - Medium
- Difficulty Level - Hard
- Explore More...
- C
- C++
- Java
- Python
- SQL
- PHP
- JavaScript
- School Programming
- Operating Systems
- DBMS
- Computer Networks
- Engineering Mathematics
- Design Patterns
- Common Interview Puzzles
- Web Technology
- G-Facts
- Computer Graphics
- Image Processing
- Project Ideas

Given two arrays A[] and B[] both of size N consisting of distinct elements, the task is to find the minimum cost to swap two… Read More »

Binary Synchronous Communication (BISYNC) is basically a character or byte-oriented form of communication which means that the groups of bits or bytes are the important… Read More »

1. Hierarchical Routing Protocol : Hierarchical Routing is the method of routing in networks that is based on hierarchical addressing. Most transmission control protocol, Internet… Read More »

In Perspective Projection the center of projection is at finite distance from projection plane. This projection produces realistic views but does not preserve relative proportions… Read More »

Test Coverage and Code coverage are the most mainstream philosophies for estimating the viability of the code. In spite of the fact that these terms… Read More »

Given an integer array arr[] of size N, the task is to construct an array consisting of N+1 strings of length N such that arr[i]… Read More »

Given an array A[], consisting of N elements, the task is to find the minimum number of swaps required such that array elements swapped to… Read More »

Given an array A[ ] consisting of non-negative integers and matrix Q[ ][ ] consisting of queries of the following two types: (1, l, val):… Read More »

Given a string str, the task is to find the number of distinct substrings that are placed consecutively in the given string.Examples: Input: str =… Read More »

Given a number N, the task is to calculate the total number of corresponding different bit in the binary representation for every consecutive number from… Read More »

Given a Tree consisting of N vertices, rooted at vertex 1 and an array val[] representing the values assigned to each vertex, and an array… Read More »

Given a Tree, the task is to find the farthest node from each node to another node in the given tree.Examples Input: Output: 2 3… Read More »

Given an array arr[], consisting of N integers, the task is to check whether the entire array is only made up of subarrays such that… Read More »

Given a binary matrix mat[][], the task is to find the size of all possible non-empty connected cells. An empty cell is denoted by 0… Read More »

Given a rooted tree having N vertices, an array values[ ], which represents the value assigned to each node, and a vertex V, the task… Read More »