## Print nodes having maximum and minimum degrees

Given an undirected graph having N nodes, the task is to print the nodes having minimum and maximum degree. Examples: Input: 1—–2 | | 3—–4… Read More »

## Maximum length sub-array which satisfies the given conditions

Given an array arr[] of N integers, the task is to find the maximum length of any sub-array of arr[] which satisfies one of the… Read More »

## Largest sub-matrix with all equal elements

Given a binary matrix of size N * M, the task is to find the largest area sub-matrix such that all elements in it are… Read More »

## Color all boxes in line such that every M consecutive boxes are unique

Given N boxes that are kept in a straight line and M colors such that M ≤ N. The position of the boxes cannot be… Read More »

## Queries for the minimum element in an array excluding the given index range

Given an array arr[] of N integers and Q queries where each query consists of an index range [L, R]. For each query, the task… Read More »

## Check if the Matrix satisfies the given conditions

Given a matrix mat[][], the task is to check whether the matrix is valid or not. A valid matrix is the matrix that satisfies the… Read More »

## Sort elements by modulo with K

Given an array arr[] of integers and an integer K. The task is to sort the elements of the given array in the increasing order… Read More »

## Count of Multiples of A ,B or C less than or equal to N

Given four integers N, A, B and C. The task is to find the count of integers from the range [1, N] which are divisible… Read More »

## time.h localtime() function in C with Examples

The localtime() function is defined in the time.h header file. The localtime( ) function return the local time of the user i.e time present at… Read More »

## Check if the rows of a binary matrix can be made unique by removing a single column

Given a binary matrix mat[][] of size M * N. The task is to check whether the row of the matrix will be unique after… Read More »

## Find out the prime numbers in the form of A+nB or B+nA

Given two integers A and B and an integer N. The task is to find out N prime numbers of the form A + nB… Read More »

## Count of triples (A, B, C) where A*C is greater than B*B

Given three integers A, B and C. The task is to count the number of triples (a, b, c) such that a * c >… Read More »

## Number of Subarrays with positive product

Given an array arr[] of N integers, the task is to find the count of subarrays with positive product. Examples: Input: arr[] = {-1, 2,… Read More »

## Write a function to get the intersection point of two Linked Lists | Set 2

There are two singly linked lists in a system. By some programming error, the end node of one of the linked list got linked to… Read More »

## Make the list non-decreasing by changing only one digit of the elements

Given an array arr[] of N integers where every element is from the range [1000, 9999]. The task is to make the array non-decreasing by… Read More »