## ADA practical 6 In Lab

January 16, 2022Surya is a student at KL University, He is currently standing in the C-Block. He has 8 friends who are situated at different Blocks (Places…

## ADA practical 6 In Lab

January 16, 2022Surya is a student at KL University, He is currently standing in the C-Block. He has 8 friends who are situated at different Blocks (Places…

## Sort an array of strings according to string lengths

December 23, 2021Given problem statement Caroline Forbes is an intelligent girl, every time she wins in any contest or programme, and also solves complex…

## Algorithm to find the smallest and largest number in a given list

November 17, 2021Write an algorithm to find the smallest and largest number in a given list. Algorithm In the algorithm we will declare two variables and…

## Number of ways to Construct the Array

September 16, 2021Your goal is to find the number of ways to construct an array such that consecutive positions contain different values. Specifically, we…

## Sherlock and Cost

September 16, 2021In this challenge, you will be given an array and must determine an array . There is a special rule: For all , . That is, can be any…

## Beautiful Pairs hackerrank Solution

September 02, 2021You are given two arrays, A and B, both containing N integers. A pair of indices is beautiful if the element of array is equal to the…

## Marc's Cakewalk hackerrank Solution

September 02, 2021Marc loves cupcakes, but he also likes to stay fit. Each cupcake has a calorie count, and Marc can walk a distance to expend those calories…

## Sherlock and MiniMax hackerrank Solution

September 02, 2021Watson gives Sherlock an array of integers. Given the endpoints of an integer range, for all M in that inclusive range, determine the…

## Candies

August 20, 2021Alice is a kindergarten teacher. She wants to give some candies to the children in her class. All the children sit in a line and each of…

## Permuting Two Arrays

August 20, 2021There are two n-element arrays of integers, A and B. Permute them into some a and b such that the relation a[i] + b[i] >= k holds for all i…

## Max and Min

August 20, 2021You will be given a list of integers,arr, and a single integer k. You must create an array of length k from elements of arr such that its…

## Sort an array according to count of set bits

August 09, 2021Given problem statment Kiran Kumar is the Assistant Professor of Computer science department so he Just ask interact with the students and…

## Lily's Homework

August 06, 2021Whenever George asks Lily to hang out, she’s busy doing homework. George wants to help her finish it faster, but he’s in over his head! Can…

## Correctness and the Loop Invariant

August 06, 2021In the previous challenge, you wrote code to perform an Insertion Sort on an unsorted array. But how would you prove that the code is…

## Find the Median

August 06, 2021Problem description The median of a list of numbers is essentially its middle element after sorting. The same number of elements occur…

## Closest Number

August 06, 2021Problem description You are given 3 numbers a, b and x. You need to output the multiple of x which is closest to pow(a,b). If more than one…

## Counting Sort 1

August 06, 2021Problem description Given a list of integers, count and return the number of times each value appears as an array of integers. Input format…

## Fraudulent Activity Notifications

August 06, 2021Given problem statment HackerLand National Bank has a simple policy for warning clients about possible fraudulent account activity. If the…

## Insertion Sort - Part 2

August 06, 2021Given problem statment In Insertion Sort Part 1, you inserted one element into an array at its correct sorted position. Using the same…

## Insertion Sort - Part 1

August 06, 2021Given problem statment Sorting One common task for computers is to sort data. For example, people might want to see all their files on a…

## Mars Exploration

August 06, 2021Given problem statment A space explorer’s ship crashed on Mars! They send a series of SOS messages to Earth for help. Letters in some of…

## Game of Thrones - I hackerrank

August 06, 2021Given problem statment Dothraki are planning an attack to usurp King Robert’s throne. King Robert learns of this conspiracy from Raven and…

## Funny string

August 06, 2021Given problem statment In this challenge, you will determine whether a string is funny or not. To determine whether a string is funny…

## Separate the Numbers

August 05, 2021Given problem statment A numeric string, s , is beautiful if it can be split into a sequence of two or more positive integers, solution in…

## Sherlock and the Valid String solution

August 05, 2021Given problem statment Sherlock considers a string to be valid if all characters of the string appear the same number of times. It is also…

## Program to find the sum of first n natural numbers

July 29, 2021Given problem statment During the final skill exam teacher was given a problem and asked everyone to write the algorithm to it, and also…