Instruction stringlengths 261 35k | Response stringclasses 1
value |
|---|---|
For this Question: Given a number N, find the value of the below equation for the given number.
Equation: -
N
∑ {(X + 1)<sup>2</sup> - (3X + 1) + X}
X = 1<b>User task:</b>
Since this is a functional problem, you don’t have to worry about the input, you just have to complete the function <b>equationSum()</... | Compilable |
For this Question: Given a number N, find the value of the below equation for the given number.
Equation: -
N
∑ {(X + 1)<sup>2</sup> - (3X + 1) + X}
X = 1<b>User task:</b>
Since this is a functional problem, you don’t have to worry about the input, you just have to complete the function <b>equationSum()</... | Compilable |
For this Question: Given a number N, find the value of the below equation for the given number.
Equation: -
N
∑ {(X + 1)<sup>2</sup> - (3X + 1) + X}
X = 1<b>User task:</b>
Since this is a functional problem, you don’t have to worry about the input, you just have to complete the function <b>equationSum()</... | Compilable |
For this Question: Given a number N, find the value of the below equation for the given number.
Equation: -
N
∑ {(X + 1)<sup>2</sup> - (3X + 1) + X}
X = 1<b>User task:</b>
Since this is a functional problem, you don’t have to worry about the input, you just have to complete the function <b>equationSum()</... | Compilable |
For this Question: Given an integer N, find the Nth number in the fibonacci series. Consider 0 and 1 to be the seed values.
In the fibonacci series, each number (Fibonacci number) is the sum of the two preceding numbers. The series with 0 and 1 as seed values will go like -
0, 1, 1, 2, 3, 5 and so on..<b>User Task:... | Compilable |
For this Question: Given an integer N, find the Nth number in the fibonacci series. Consider 0 and 1 to be the seed values.
In the fibonacci series, each number (Fibonacci number) is the sum of the two preceding numbers. The series with 0 and 1 as seed values will go like -
0, 1, 1, 2, 3, 5 and so on..<b>User Task:... | Compilable |
For this Question: We need a problem on xor again. Given an array A of N integers (1- indexed), you need to find the sum of (N- i) xor A[i] for all i from 1 to N.The first line of the input contains an integer N, the number of elements of the array.
The second line of the input contains N singly spaced integers of the... | Compilable |
For this Question: We need a problem on xor again. Given an array A of N integers (1- indexed), you need to find the sum of (N- i) xor A[i] for all i from 1 to N.The first line of the input contains an integer N, the number of elements of the array.
The second line of the input contains N singly spaced integers of the... | Compilable |
For this Question: We need a problem on xor again. Given an array A of N integers (1- indexed), you need to find the sum of (N- i) xor A[i] for all i from 1 to N.The first line of the input contains an integer N, the number of elements of the array.
The second line of the input contains N singly spaced integers of the... | Compilable |
For this Question: Given an array Arr of N integers, your task is to print the sum of elements present at even places and print the product of elements present at the odd places.
Note:- Consider the first element to start from 1.The first line of input contains a single integer N, the next line of input contains N s... | Compilable |
For this Question: Given an array Arr of N integers, your task is to print the sum of elements present at even places and print the product of elements present at the odd places.
Note:- Consider the first element to start from 1.The first line of input contains a single integer N, the next line of input contains N s... | Compilable |
For this Question: Given an array Arr of N integers, your task is to print the sum of elements present at even places and print the product of elements present at the odd places.
Note:- Consider the first element to start from 1.The first line of input contains a single integer N, the next line of input contains N s... | Compilable |
For this Question: Given two integers N and K. Construct a max diversity string of length N and period K. Among all possible strings, find the lexographically minimum string.
A max diverse string is a string with maximum number of different characters.
A string with period K is a string made by a string of length K r... | Compilable |
For this Question: Given two integers N and K. Construct a max diversity string of length N and period K. Among all possible strings, find the lexographically minimum string.
A max diverse string is a string with maximum number of different characters.
A string with period K is a string made by a string of length K r... | Compilable |
For this Question: Given two integers N and K. Construct a max diversity string of length N and period K. Among all possible strings, find the lexographically minimum string.
A max diverse string is a string with maximum number of different characters.
A string with period K is a string made by a string of length K r... | Compilable |
For this Question: From wiki-
The Tower of Hanoi is a mathematical puzzle where we have 3 rods and N disks. The puzzle starts with all the disks in ascending order of size on the first row. The objective of the puzzle is to move the entire stack to another rod, obeying the following simple rules:
1. Only one disk c... | Compilable |
For this Question: From wiki-
The Tower of Hanoi is a mathematical puzzle where we have 3 rods and N disks. The puzzle starts with all the disks in ascending order of size on the first row. The objective of the puzzle is to move the entire stack to another rod, obeying the following simple rules:
1. Only one disk c... | Compilable |
For this Question: From wiki-
The Tower of Hanoi is a mathematical puzzle where we have 3 rods and N disks. The puzzle starts with all the disks in ascending order of size on the first row. The objective of the puzzle is to move the entire stack to another rod, obeying the following simple rules:
1. Only one disk c... | Compilable |
For this Question: From wiki-
The Tower of Hanoi is a mathematical puzzle where we have 3 rods and N disks. The puzzle starts with all the disks in ascending order of size on the first row. The objective of the puzzle is to move the entire stack to another rod, obeying the following simple rules:
1. Only one disk c... | Compilable |
For this Question: You are given two numbers n1 and n2. You need to find the sum of the products of their corresponding digits. So, for a number n1= 6 and n2 = 34, you'll do (6*4)+(0*3) = 24.<b>User Task:</b>
Since this will be a functional problem, you don't have to take input. You just have to complete the function ... | Compilable |
For this Question: You are given two numbers n1 and n2. You need to find the sum of the products of their corresponding digits. So, for a number n1= 6 and n2 = 34, you'll do (6*4)+(0*3) = 24.<b>User Task:</b>
Since this will be a functional problem, you don't have to take input. You just have to complete the function ... | Compilable |
For this Question: You are given two numbers n1 and n2. You need to find the sum of the products of their corresponding digits. So, for a number n1= 6 and n2 = 34, you'll do (6*4)+(0*3) = 24.<b>User Task:</b>
Since this will be a functional problem, you don't have to take input. You just have to complete the function ... | Compilable |
For this Question: You are given a positive integer N. Print "Yes" if N is a multiple of 3, otherwise, print "No".The input consists of a single integer N.
<b> Constraints: </b>
1 ≤ N ≤ 1000If N is a multiple of 3, print "Yes". Otherwise, print "No" (without the quotation marks). Note that the <b>output is ca... | Compilable |
For this Question: Given a singly linked list, delete middle node of the linked list. For example, if given linked list is 1->2->3->4->5 then linked list should be modified to 1->2->4->5.
If there are even nodes, then there would be two middle nodes, we need to delete the second middle element. For example, if given... | Compilable |
For this Question: Sara has 2 brothers which initially have X and Y candies with them. Sara has also N candies with her. Sara wants to distribute her candies to his brothers such that both the brother have an equal amount of candies at last. Given the values of X, Y, and N, your task is to tell Sara whether she can dis... | Compilable |
For this Question: Sara has 2 brothers which initially have X and Y candies with them. Sara has also N candies with her. Sara wants to distribute her candies to his brothers such that both the brother have an equal amount of candies at last. Given the values of X, Y, and N, your task is to tell Sara whether she can dis... | Compilable |
For this Question: Sara has 2 brothers which initially have X and Y candies with them. Sara has also N candies with her. Sara wants to distribute her candies to his brothers such that both the brother have an equal amount of candies at last. Given the values of X, Y, and N, your task is to tell Sara whether she can dis... | Compilable |
For this Question: Sara has 2 brothers which initially have X and Y candies with them. Sara has also N candies with her. Sara wants to distribute her candies to his brothers such that both the brother have an equal amount of candies at last. Given the values of X, Y, and N, your task is to tell Sara whether she can dis... | Compilable |
For this Question: Check if the given string is a palindrome or not?
Palindromes are a numbers, phrases or words that reads same both the ways, backward as well as forward. For example, 1331 is a palindrome because on reversing the digits the number remains the same. But 123 is not a palindrome, as on reversing the di... | Compilable |
For this Question: Check if the given string is a palindrome or not?
Palindromes are a numbers, phrases or words that reads same both the ways, backward as well as forward. For example, 1331 is a palindrome because on reversing the digits the number remains the same. But 123 is not a palindrome, as on reversing the di... | Compilable |
For this Question: Check if the given string is a palindrome or not?
Palindromes are a numbers, phrases or words that reads same both the ways, backward as well as forward. For example, 1331 is a palindrome because on reversing the digits the number remains the same. But 123 is not a palindrome, as on reversing the di... | Compilable |
For this Question: Check if the given string is a palindrome or not?
Palindromes are a numbers, phrases or words that reads same both the ways, backward as well as forward. For example, 1331 is a palindrome because on reversing the digits the number remains the same. But 123 is not a palindrome, as on reversing the di... | Compilable |
For this Question: Given an integer, your task is to check whether the given integer is even or odd.
If the integer is even print 0 else if it is odd print 1.The input contains a single integer N.
Constraint:
1 ≤ N ≤10000If the integer is even print 0 else if it is odd print 1.Sample Input:-
15
Sample Ou... | Compilable |
For this Question: Given an integer, your task is to check whether the given integer is even or odd.
If the integer is even print 0 else if it is odd print 1.The input contains a single integer N.
Constraint:
1 ≤ N ≤10000If the integer is even print 0 else if it is odd print 1.Sample Input:-
15
Sample Ou... | Compilable |
For this Question: You are given a positive integer N. Print "Yes" if N is a multiple of 3, otherwise, print "No".The input consists of a single integer N.
<b> Constraints: </b>
1 ≤ N ≤ 1000If N is a multiple of 3, print "Yes". Otherwise, print "No" (without the quotation marks). Note that the <b>output is ca... | Compilable |
For this Question: Given an integer, your task is to check whether the given integer is even or odd.
If the integer is even print 0 else if it is odd print 1.The input contains a single integer N.
Constraint:
1 ≤ N ≤10000If the integer is even print 0 else if it is odd print 1.Sample Input:-
15
Sample Ou... | Compilable |
For this Question: Given an integer, your task is to check whether the given integer is even or odd.
If the integer is even print 0 else if it is odd print 1.The input contains a single integer N.
Constraint:
1 ≤ N ≤10000If the integer is even print 0 else if it is odd print 1.Sample Input:-
15
Sample Ou... | Compilable |
For this Question: Hawkeye has been assigned to eliminate n monsters, the i<sup>th</sup> of which is of type a<sub>i</sub>. In one move, he can do either of the following:
i. Shoot down atmost any k monsters. In other words, he can shoot down any set of monsters such that the size of that set is smaller than or equa... | Compilable |
For this Question: Hawkeye has been assigned to eliminate n monsters, the i<sup>th</sup> of which is of type a<sub>i</sub>. In one move, he can do either of the following:
i. Shoot down atmost any k monsters. In other words, he can shoot down any set of monsters such that the size of that set is smaller than or equa... | Compilable |
For this Question: Hawkeye has been assigned to eliminate n monsters, the i<sup>th</sup> of which is of type a<sub>i</sub>. In one move, he can do either of the following:
i. Shoot down atmost any k monsters. In other words, he can shoot down any set of monsters such that the size of that set is smaller than or equa... | Compilable |
For this Question: Hawkeye has been assigned to eliminate n monsters, the i<sup>th</sup> of which is of type a<sub>i</sub>. In one move, he can do either of the following:
i. Shoot down atmost any k monsters. In other words, he can shoot down any set of monsters such that the size of that set is smaller than or equa... | Compilable |
For this Question: Given an integer N, subtract the first digit of the number N from it i. e if n is 245 then subtract 2 from it making it 245-2 = 243. Keep on doing this operation until the number becomes 0.
Your task is to calculate the number of operation required to make this number N zero.<b>User Task:</b>
Since... | Compilable |
For this Question: Given an integer N, subtract the first digit of the number N from it i. e if n is 245 then subtract 2 from it making it 245-2 = 243. Keep on doing this operation until the number becomes 0.
Your task is to calculate the number of operation required to make this number N zero.<b>User Task:</b>
Since... | Compilable |
For this Question: Given an integer N, subtract the first digit of the number N from it i. e if n is 245 then subtract 2 from it making it 245-2 = 243. Keep on doing this operation until the number becomes 0.
Your task is to calculate the number of operation required to make this number N zero.<b>User Task:</b>
Since... | Compilable |
For this Question: Given an integer N, subtract the first digit of the number N from it i. e if n is 245 then subtract 2 from it making it 245-2 = 243. Keep on doing this operation until the number becomes 0.
Your task is to calculate the number of operation required to make this number N zero.<b>User Task:</b>
Since... | Compilable |
For this Question: Given a linked list consisting of N nodes and two integers M and K. Your task is to add element K at the Mth position from the start of the linked list<b>User Task:</b>
Since this will be a functional problem, you don't have to take input. You just have to complete the function <b>addElement()</b> t... | Compilable |
For this Question: A magic number is a natural number that contains both the digits 7 and 9 in it. For eg:- 79, 879, 53729 etc.
Given a number N, your task is to find the closest Magic number from the given number N.
Note:- If more than one answer exists return the minimum one<b>User Task:</b>
Since this will be ... | Compilable |
For this Question: A magic number is a natural number that contains both the digits 7 and 9 in it. For eg:- 79, 879, 53729 etc.
Given a number N, your task is to find the closest Magic number from the given number N.
Note:- If more than one answer exists return the minimum one<b>User Task:</b>
Since this will be ... | Compilable |
For this Question: A magic number is a natural number that contains both the digits 7 and 9 in it. For eg:- 79, 879, 53729 etc.
Given a number N, your task is to find the closest Magic number from the given number N.
Note:- If more than one answer exists return the minimum one<b>User Task:</b>
Since this will be ... | Compilable |
For this Question: A magic number is a natural number that contains both the digits 7 and 9 in it. For eg:- 79, 879, 53729 etc.
Given a number N, your task is to find the closest Magic number from the given number N.
Note:- If more than one answer exists return the minimum one<b>User Task:</b>
Since this will be ... | Compilable |
For this Question: Check if the given string is a palindrome or not?
Palindromes are a numbers, phrases or words that reads same both the ways, backward as well as forward. For example, 1331 is a palindrome because on reversing the digits the number remains the same. But 123 is not a palindrome, as on reversing the di... | Compilable |
For this Question: Check if the given string is a palindrome or not?
Palindromes are a numbers, phrases or words that reads same both the ways, backward as well as forward. For example, 1331 is a palindrome because on reversing the digits the number remains the same. But 123 is not a palindrome, as on reversing the di... | Compilable |
For this Question: Check if the given string is a palindrome or not?
Palindromes are a numbers, phrases or words that reads same both the ways, backward as well as forward. For example, 1331 is a palindrome because on reversing the digits the number remains the same. But 123 is not a palindrome, as on reversing the di... | Compilable |
For this Question: Check if the given string is a palindrome or not?
Palindromes are a numbers, phrases or words that reads same both the ways, backward as well as forward. For example, 1331 is a palindrome because on reversing the digits the number remains the same. But 123 is not a palindrome, as on reversing the di... | Compilable |
For this Question: Check if the given string is a palindrome or not?
Palindromes are a numbers, phrases or words that reads same both the ways, backward as well as forward. For example, 1331 is a palindrome because on reversing the digits the number remains the same. But 123 is not a palindrome, as on reversing the di... | Compilable |
For this Question: Check if the given string is a palindrome or not?
Palindromes are a numbers, phrases or words that reads same both the ways, backward as well as forward. For example, 1331 is a palindrome because on reversing the digits the number remains the same. But 123 is not a palindrome, as on reversing the di... | Compilable |
For this Question: Check if the given string is a palindrome or not?
Palindromes are a numbers, phrases or words that reads same both the ways, backward as well as forward. For example, 1331 is a palindrome because on reversing the digits the number remains the same. But 123 is not a palindrome, as on reversing the di... | Compilable |
For this Question: Check if the given string is a palindrome or not?
Palindromes are a numbers, phrases or words that reads same both the ways, backward as well as forward. For example, 1331 is a palindrome because on reversing the digits the number remains the same. But 123 is not a palindrome, as on reversing the di... | Compilable |
For this Question: A magic number is a natural number that contains both the digits 7 and 9 in it. For eg:- 79, 879, 53729 etc.
Given a number N, your task is to find the closest Magic number from the given number N.
Note:- If more than one answer exists return the minimum one<b>User Task:</b>
Since this will be ... | Compilable |
For this Question: A magic number is a natural number that contains both the digits 7 and 9 in it. For eg:- 79, 879, 53729 etc.
Given a number N, your task is to find the closest Magic number from the given number N.
Note:- If more than one answer exists return the minimum one<b>User Task:</b>
Since this will be ... | Compilable |
For this Question: A magic number is a natural number that contains both the digits 7 and 9 in it. For eg:- 79, 879, 53729 etc.
Given a number N, your task is to find the closest Magic number from the given number N.
Note:- If more than one answer exists return the minimum one<b>User Task:</b>
Since this will be ... | Compilable |
For this Question: A magic number is a natural number that contains both the digits 7 and 9 in it. For eg:- 79, 879, 53729 etc.
Given a number N, your task is to find the closest Magic number from the given number N.
Note:- If more than one answer exists return the minimum one<b>User Task:</b>
Since this will be ... | Compilable |
For this Question: Sara is standing in a line for her turn to see the doctor. N people are standing in front of Sara, and the doctor takes exactly X minutes for each person. Sara wants to know the time after which her number comes. Since Sara is weak in maths, your task is calculating the time for her turn.You don't ha... | Compilable |
For this Question: Sara is standing in a line for her turn to see the doctor. N people are standing in front of Sara, and the doctor takes exactly X minutes for each person. Sara wants to know the time after which her number comes. Since Sara is weak in maths, your task is calculating the time for her turn.You don't ha... | Compilable |
For this Question: Sara is standing in a line for her turn to see the doctor. N people are standing in front of Sara, and the doctor takes exactly X minutes for each person. Sara wants to know the time after which her number comes. Since Sara is weak in maths, your task is calculating the time for her turn.You don't ha... | Compilable |
For this Question: Sara is standing in a line for her turn to see the doctor. N people are standing in front of Sara, and the doctor takes exactly X minutes for each person. Sara wants to know the time after which her number comes. Since Sara is weak in maths, your task is calculating the time for her turn.You don't ha... | Compilable |
For this Question: Sara is standing in a line for her turn to see the doctor. N people are standing in front of Sara, and the doctor takes exactly X minutes for each person. Sara wants to know the time after which her number comes. Since Sara is weak in maths, your task is calculating the time for her turn.You don't ha... | Compilable |
For this Question: Sara is standing in a line for her turn to see the doctor. N people are standing in front of Sara, and the doctor takes exactly X minutes for each person. Sara wants to know the time after which her number comes. Since Sara is weak in maths, your task is calculating the time for her turn.You don't ha... | Compilable |
For this Question: Alexa is a very kind girl. She has 'x' red gems and 'y' blue gems. She wants to distribute them among her two friends (Alice and Julia).
But she will only distribute them if she can give equal number of each colour of gems to Alice and Julia. Further, she must distribute all available gems in thi... | Compilable |
For this Question: Alexa is a very kind girl. She has 'x' red gems and 'y' blue gems. She wants to distribute them among her two friends (Alice and Julia).
But she will only distribute them if she can give equal number of each colour of gems to Alice and Julia. Further, she must distribute all available gems in thi... | Compilable |
For this Question: Alexa is a very kind girl. She has 'x' red gems and 'y' blue gems. She wants to distribute them among her two friends (Alice and Julia).
But she will only distribute them if she can give equal number of each colour of gems to Alice and Julia. Further, she must distribute all available gems in thi... | Compilable |
For this Question: Rick's family and Jerry are playing Tic Tac Toe. Rules are simple:
<li> Game is played in pairs.
<li> If Rick plays against anyone, Rick wins.
<li> If Jerry plays against anyone, Jerry Loses.
<li> A game between any other players is a draw.
Given a pair of players, find who wins the game or if t... | Compilable |
For this Question: Rick's family and Jerry are playing Tic Tac Toe. Rules are simple:
<li> Game is played in pairs.
<li> If Rick plays against anyone, Rick wins.
<li> If Jerry plays against anyone, Jerry Loses.
<li> A game between any other players is a draw.
Given a pair of players, find who wins the game or if t... | Compilable |
For this Question: Rick's family and Jerry are playing Tic Tac Toe. Rules are simple:
<li> Game is played in pairs.
<li> If Rick plays against anyone, Rick wins.
<li> If Jerry plays against anyone, Jerry Loses.
<li> A game between any other players is a draw.
Given a pair of players, find who wins the game or if t... | Compilable |
For this Question: Given an integer, your task is to check whether the given integer is even or odd.
If the integer is even print 0 else if it is odd print 1.The input contains a single integer N.
Constraint:
1 ≤ N ≤10000If the integer is even print 0 else if it is odd print 1.Sample Input:-
15
Sample Ou... | Compilable |
For this Question: Given an integer, your task is to check whether the given integer is even or odd.
If the integer is even print 0 else if it is odd print 1.The input contains a single integer N.
Constraint:
1 ≤ N ≤10000If the integer is even print 0 else if it is odd print 1.Sample Input:-
15
Sample Ou... | Compilable |
For this Question: Given an array A of positive integers. Your task is to sort them in such a way that the first part of the array contains odd numbers sorted in descending order, rest portion contains even numbers sorted in ascending order.First line of each test case contains an integer N denoting the size of the arr... | Compilable |
For this Question: Given an array A of positive integers. Your task is to sort them in such a way that the first part of the array contains odd numbers sorted in descending order, rest portion contains even numbers sorted in ascending order.First line of each test case contains an integer N denoting the size of the arr... | Compilable |
For this Question: Given an array A of positive integers. Your task is to sort them in such a way that the first part of the array contains odd numbers sorted in descending order, rest portion contains even numbers sorted in ascending order.First line of each test case contains an integer N denoting the size of the arr... | Compilable |
For this Question: Given an array A of positive integers. Your task is to sort them in such a way that the first part of the array contains odd numbers sorted in descending order, rest portion contains even numbers sorted in ascending order.First line of each test case contains an integer N denoting the size of the arr... | Compilable |
For this Question: Given the radius of the circle, your task is to calculate its area.
<b>Note:- </b>
(i) take π as 3.14.
(ii) Print the area up to 2 decimal places.<b>User Task:</b>
Since this will be a functional problem, you don't have to take input. You just have to complete the function <b>Area()</b> that tak... | Compilable |
For this Question: Given the radius of the circle, your task is to calculate its area.
<b>Note:- </b>
(i) take π as 3.14.
(ii) Print the area up to 2 decimal places.<b>User Task:</b>
Since this will be a functional problem, you don't have to take input. You just have to complete the function <b>Area()</b> that tak... | Compilable |
For this Question: You are given a positive integer N. Print "Yes" if N is a multiple of 3, otherwise, print "No".The input consists of a single integer N.
<b> Constraints: </b>
1 ≤ N ≤ 1000If N is a multiple of 3, print "Yes". Otherwise, print "No" (without the quotation marks). Note that the <b>output is ca... | Compilable |
For this Question: Given an integer N, find the Nth number in the fibonacci series. Consider 0 and 1 to be the seed values.
In the fibonacci series, each number (Fibonacci number) is the sum of the two preceding numbers. The series with 0 and 1 as seed values will go like -
0, 1, 1, 2, 3, 5 and so on..<b>User Task:... | Compilable |
For this Question: Given an integer N, find the Nth number in the fibonacci series. Consider 0 and 1 to be the seed values.
In the fibonacci series, each number (Fibonacci number) is the sum of the two preceding numbers. The series with 0 and 1 as seed values will go like -
0, 1, 1, 2, 3, 5 and so on..<b>User Task:... | Compilable |
For this Question: There are N trees in Terry's front yard. He is supposed to measures the height of each tree and find the average height of trees in his yard. What is the average height of a tree in Terry's front yard?
Note:- Print your answer as floor value (average height)The first line contains N: numbers of t... | Compilable |
For this Question: There are N trees in Terry's front yard. He is supposed to measures the height of each tree and find the average height of trees in his yard. What is the average height of a tree in Terry's front yard?
Note:- Print your answer as floor value (average height)The first line contains N: numbers of t... | Compilable |
For this Question: There are N trees in Terry's front yard. He is supposed to measures the height of each tree and find the average height of trees in his yard. What is the average height of a tree in Terry's front yard?
Note:- Print your answer as floor value (average height)The first line contains N: numbers of t... | Compilable |
For this Question: There are N trees in Terry's front yard. He is supposed to measures the height of each tree and find the average height of trees in his yard. What is the average height of a tree in Terry's front yard?
Note:- Print your answer as floor value (average height)The first line contains N: numbers of t... | Compilable |
For this Question: There are N trees in Terry's front yard. He is supposed to measures the height of each tree and find the average height of trees in his yard. What is the average height of a tree in Terry's front yard?
Note:- Print your answer as floor value (average height)The first line contains N: numbers of t... | Compilable |
For this Question: There are N trees in Terry's front yard. He is supposed to measures the height of each tree and find the average height of trees in his yard. What is the average height of a tree in Terry's front yard?
Note:- Print your answer as floor value (average height)The first line contains N: numbers of t... | Compilable |
For this Question: There are N trees in Terry's front yard. He is supposed to measures the height of each tree and find the average height of trees in his yard. What is the average height of a tree in Terry's front yard?
Note:- Print your answer as floor value (average height)The first line contains N: numbers of t... | Compilable |
For this Question: There are N trees in Terry's front yard. He is supposed to measures the height of each tree and find the average height of trees in his yard. What is the average height of a tree in Terry's front yard?
Note:- Print your answer as floor value (average height)The first line contains N: numbers of t... | Compilable |
For this Question: Given a singly linked list, delete middle node of the linked list. For example, if given linked list is 1->2->3->4->5 then linked list should be modified to 1->2->4->5.
If there are even nodes, then there would be two middle nodes, we need to delete the second middle element. For example, if given... | Compilable |
For this Question: Given an integer N, find all possible pairs of A, and B such that A + B = N and A and B both are natural numbers.<b>User Task:</b>
Since this will be a functional problem, you don't have to take input. You just have to complete the function <b>Allpair()</b> that takes integer N as a parameter.
Co... | Compilable |
For this Question: Given an integer N, find all possible pairs of A, and B such that A + B = N and A and B both are natural numbers.<b>User Task:</b>
Since this will be a functional problem, you don't have to take input. You just have to complete the function <b>Allpair()</b> that takes integer N as a parameter.
Co... | Compilable |
For this Question: Given an integer N, find all possible pairs of A, and B such that A + B = N and A and B both are natural numbers.<b>User Task:</b>
Since this will be a functional problem, you don't have to take input. You just have to complete the function <b>Allpair()</b> that takes integer N as a parameter.
Co... | Compilable |
For this Question: Given an integer N, find all possible pairs of A, and B such that A + B = N and A and B both are natural numbers.<b>User Task:</b>
Since this will be a functional problem, you don't have to take input. You just have to complete the function <b>Allpair()</b> that takes integer N as a parameter.
Co... | Compilable |
For this Question: Check if the given string is a palindrome or not?
Palindromes are a numbers, phrases or words that reads same both the ways, backward as well as forward. For example, 1331 is a palindrome because on reversing the digits the number remains the same. But 123 is not a palindrome, as on reversing the di... | Compilable |
For this Question: Check if the given string is a palindrome or not?
Palindromes are a numbers, phrases or words that reads same both the ways, backward as well as forward. For example, 1331 is a palindrome because on reversing the digits the number remains the same. But 123 is not a palindrome, as on reversing the di... | Compilable |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.