## First subarray with negative sum from the given Array

Given an array arr[] consisting of N integers, the task is to find the start and end indices of the first subarray with a Negative… Read More »

- Must do Math for Competitive Programming
- Which C++ libraries are useful for competitive programming?
- Breadth First Search without using Queue
- 7 Best Coding Challenge Websites in 2020
- Minimize the maximum difference between adjacent elements in an array
- Which Java libraries are useful for competitive programming?
- Speed up Code executions with help of Pragma in C/C++
- Which Python Modules are useful for competitive programming?
- Setting up a C++ Competitive Programming Environment
- Logarithm tricks for Competitive Programming
- Basic Algorithm Techniques Not Taught in Academics
- Writing code faster during Competitive Programming in C++
- Print all possible combinations of the string by replacing '$' with any other digit from the string
- Count of subarrays of an Array having all unique digits
- Check if sum of Fibonacci elements in an Array is a Fibonacci number or not
- Default values in a Map in C++ STL
- Move all zeroes to end of array using Two-Pointers
- Count the number of ways to construct the target string
- How To Approach A Coding Problem ?
- Sum of GCD of all possible sequences
- Minimize the maximum difference of adjacent elements after at most K insertions
- Kth most frequent Character in a given String
- Count of substrings of length K with exactly K distinct characters
- Maximum LCM among all pairs (i, j) from the given Array
- Count of subarrays which start and end with the same element
- Minimum cost of reducing Array by merging any adjacent elements repetitively
- Finding Median of unsorted Array in linear time using C++ STL
- Important functions of STL Components in C++
- Competitive Programming vs Software Development - Where Should I Invest My Time?
- Shortest path in a directed graph by Dijkstra’s algorithm

Given an array arr[] consisting of N integers, the task is to find the start and end indices of the first subarray with a Negative… Read More »

Two players are playing a game starting with a number n. In each turn, a player can make any one of the subsequent moves: Divide… Read More »

Given a Binary Tree, the task is to print the nodes that have grandchildren. Examples: Input: Output: 20 8 Explanation: 20 and 8 are the… Read More »

Given two nodes of a binary tree v1 and v2, the task is to check if two nodes are on the same path in a… Read More »

Given a number N, the task is to find the number of quadraples such that a2 + b2 = c2 + d2 where (1 <=… Read More »

Given an array arr[] of N positive integers and a number K, the task is to find the maximum value of bitwise OR of the… Read More »

Given a positive integer N, the task is to find the sum of divisors of all the numbers from 1 to N. Examples: Input: N… Read More »

Given an array arr[] of positive integers. The task is to reverse a subarray to minimize the sum of elements at even places and print… Read More »

Given two integers N and K, the task is to count the numbers up to N digits such that no two zeros are adjacents and… Read More »

Given an integer N, the task is to count the number of square-free divisors of the given number. A number is said to be square-free,… Read More »

Given an array arr[] of N numbers. We can merge two adjacent numbers into one and the cost of merging the two numbers is equal… Read More »

Given a positive integer N, the task is to find the largest integer M such that 0 <= M < N and XOR(M, N) is… Read More »

Given an array arr[] consisting of N integers, the task is to to modify the array such that arr[index] = index using minimum number of… Read More »

Given an integer K and an array arr[] of N integers, each of which is the first term and common difference of an Arithemetic Progression,… Read More »

Given a string S of length N, consisting of only opening ‘(‘ and closing ‘)‘ parenthesis. The task is to find all indices ‘K‘ such… Read More »