## Series summation if T(n) is given and n is very large

Given a sequence whose nth term is T(n) = n2 – (n – 1)2 The task is to evaluate the sum of first n terms… Read More »

- How can one become good at Data structures and Algorithms easily?
- Cracking Technical Interviews
- Print the nodes of binary tree as they become the leaf node
- Reach the numbers by making jumps of two given lengths
- Dijkstra's shortest path with minimum edges
- Shannon-Fano Algorithm for Data Compression
- Rearrange Odd and Even values in Alternate Fashion in Ascending Order
- How to write a Pseudo Code?
- Sort the array of strings according to alphabetical order defined by another string
- Longest subsequence such that adjacent elements have at least one common digit
- Code Optimization Technique (logical AND and logical OR)
- Iterative Letter Combinations of a Phone Number
- Check if it is possible to reach a number by making jumps of two given length
- Smallest Pair Sum in an array
- Sum of similarities of string with all of its suffixes
- Dividing a Large file into Separate Modules in C/C++, Java and Python
- Merge K sorted arrays | Set 3 ( Using Divide and Conquer Approach )
- Ternary Search
- Find the number in a range having maximum product of the digits
- Count pairs in array whose sum is divisible by K
- Length of the longest alternating subarray
- Largest perfect square number in an Array
- Smallest power of 2 which is greater than or equal to sum of array elements
- Travelling Salesman Problem implementation using BackTracking
- Count common characters in two strings
- Count distinct substrings that contain some characters at most k times
- Number of array elements derivable from D after performing certain operations
- Find alphabet in a Matrix which has maximum number of stars around it
- Array Manipulation and Sum
- Choose atleast two elements from array such that their GCD is 1 and cost is minimum

Given a sequence whose nth term is T(n) = n2 – (n – 1)2 The task is to evaluate the sum of first n terms… Read More »

Given an array arr[] of n integers and an integer K. In one operation every element of the array is replaced by the difference of… Read More »

Given two numbers n and r, the task is to find the value of nPr. nPr represents n permutation r which is calculated as n!/(n-k)!.… Read More »

Given two integer N and M, the task is to find the number of distinct numbers having N 0’s and M 1’s with no leading… Read More »

Given an array arr[] of N integers and an integer X. Element arr[i] in array denotes the cost to use 2i. The task is to… Read More »

Given an array arr[] and an integer K, the task is to find the Kth odd element from the given array. Examples: Input: arr[] =… Read More »

Given a five digit number N. The task is to find the last five digits of the given number raised to the power of 5… Read More »

Given an array arr[], the task is to compute the sum of (max{A} – min{A}) for every non-empty subset A of the array arr[]. Examples:… Read More »

Given an array arr[], the task is to find the number of ways to remove elements from the array so as to maximize the arithmetic… Read More »

Given an array arr[] of size n whose elements are from the range [1, n]. The task is to find maximum value of |arr[0] –… Read More »

Given an integer N, the task is to find the count of all N digit numbers such that num + Rev(num) = 10N – 1… Read More »

Given an integer n, the task is to count the numbers having only 1 set bit in the range [0, n]. Examples: Input: n =… Read More »

Given a string str, the task is to encrypt the string with the given encryption algorithm. The 1st character of the string will be repeated… Read More »

Given a directed graph G with N vertices and M edges. The task is to find the length of the longest directed path in Graph.… Read More »

Given an array arr[], the task is to find the smallest possible integer (other than 1) which divides every element of the given array. Examples:… Read More »