Given three values, N, L and R, the task is to calculate the sum of binomial coefficients (nCr) for all values of r from L… Read More
Tag Archives: binomial coefficient
Given a number N, the task is to count the combinations of K numbers from 1 to N having a sum equal to N, with… Read More
Given an array arr[] consisting of N integers, the task is to find the remaining array element after subtracting each element from its next adjacent… Read More
Given an integer N, the task is to count the number of even and odd binomial coefficients up to Nth power. Examples: Input: N =… Read More
Given two integers M and X, the task is to find the number of sequences of length M that can be generated comprising X and… Read More
Given an array, arr[] of size N consisting of elements from the range [1, N], that represents the order, in which the elements are inserted… Read More
Given an integer N, the task is to find the number of distinct bracket sequences that can be formed using 2 * N brackets such… Read More
Given three integers N, M and K, the task is to calculate the sum of products of Binomial Coefficients C(N, i) and C(M, K –… Read More
Given an integer N, the task is to find the Central binomial coefficient. The first few Central binomial coefficients for N = 0, 1, 2, 3… are … Read More
Given N blocks, out of which K is colored. These K-colored blocks are denoted by an array arr[]. The task is to count the number… Read More
Given a string str and two integers P and Q. The task is to find the total count of words that can be formed by… Read More
Given a string str and Q queries. Each query consists of an integer K. The task is to find the number of ways of choosing… Read More
Given the NxN grid of horizontal and vertical roads. The task is to find out the number of ways that the person can go from… Read More
Given a complete graph with N vertices, the task is to count the number of ways to remove edges such that the resulting graph has… Read More