Arnab Chakraborty has Published 4362 Answers

C++ Program to get minimum difference between jigsaw puzzle pieces

Arnab Chakraborty

Arnab Chakraborty

Updated on 08-Apr-2022 11:50:17

Suppose we have an array A with m elements and another number n. Amal decided given a present for his n friend, so he will give each of them a jigsaw puzzle. The shop assistant told him that there are m puzzles in the shop, but they might differ in ... Read More

C++ Program to get blocks position after right side rotation

Arnab Chakraborty

Arnab Chakraborty

Updated on 08-Apr-2022 11:47:30

Suppose we have an array A with n elements. A[i] represents there are A[i] number of blocks stacked on top of each other at ith column. The entire blocks are inside a closed transparent boundary box. Now if we rotate the entire big box clockwise 90°, then due to change ... Read More

C++ Program to find length of maximum non-decreasing subsegment

Arnab Chakraborty

Arnab Chakraborty

Updated on 08-Apr-2022 11:44:14

Suppose we have an array A with n elements. Amal has decided to make some money doing business on the Internet for exactly n days. On the i-th day he makes A[i] amount of money. Amal loves progress, that's why he wants to know the length of the maximum non-decreasing ... Read More

C++ Program to get number at position k after positioning n natural numbers

Arnab Chakraborty

Arnab Chakraborty

Updated on 08-Apr-2022 11:41:50

Suppose we have two numbers n and k. We are determined to rearrange natural numbers. But there are too many natural numbers, so we have decided to start with the first n. Pick the following sequence of numbers: firstly, all odd integers from 1 to n (in ascending order), then ... Read More

C++ Program to check joke programming code is generating output or not

Arnab Chakraborty

Arnab Chakraborty

Updated on 08-Apr-2022 11:39:37

Suppose we have a string S with n characters. In a joke programming language, there are only 4 instructions."H" to print "Hello World""Q" to print its source code"9" to print "99 bottles of juice""+" to increment the value stored in accumulatorInstructions "H" and "Q" are case-sensitive and they must be ... Read More

C++ Program to check player position is dangerous or not in football match

Arnab Chakraborty

Arnab Chakraborty

Updated on 08-Apr-2022 11:36:50

Suppose we have a binary string S of size n. Amal loves football very much. One day, he was watching a match, he was writing the players' current positions on a piece of paper. The given string is the written position. A zero corresponds to players of one team; a ... Read More

C++ Program to check April fool news is fake or real

Arnab Chakraborty

Arnab Chakraborty

Updated on 08-Apr-2022 11:34:14

Suppose we have a string S with n characters. As it's the first of April, Amal is suspecting that the news she reads today are fake, and he does not want to look silly in front of all the contestants. He knows that a news is fake if it contains ... Read More

C++ Program to get minimum perimeter of rectangle whose area is n

Arnab Chakraborty

Arnab Chakraborty

Updated on 08-Apr-2022 11:31:27

Suppose we have a number n. We are developing a project to build a new data center. The plot of this data center will be a rectangle with an area of exactly n square meters. Each side of the data center must be an integer. We want to minimize the ... Read More

C++ Program to get maximum area of rectangle made from line segments

Arnab Chakraborty

Arnab Chakraborty

Updated on 08-Apr-2022 11:28:51

Suppose we have an array A with four lines. Amal wants to draw four line segments on a sheet of paper. The i-th segment to have its length equal to A[i]. These segments can intersect with each other, and each segment should be either horizontal or vertical. Amal wants to ... Read More

C++ Program to find number of RBS string we can form bracket sequences

Arnab Chakraborty

Arnab Chakraborty

Updated on 08-Apr-2022 11:27:07

Suppose we have a string S with brackets. There are two types of brackets '(' ')' and '[', ']'. A string is called a regular bracket sequence (RBS) if it follows following types −empty string;'(' | RBS | ')';'[' | RBS | ']';RBS | RBS.Where '|' is a concatenation of ... Read More

1 2 3 4 5 6 7 ... 437 Next
Advertisements