AfterAcademy Tech
You are given an array A[] consisting of n elements. You need to find and return the number which appears more than n/2 times.
28 Oct 2019
In this blog, we will learn about API. We will see what exactly is API and by the end of this blog, you will get the knowledge of APIs with the help of some conceptual and practical example.
22 Oct 2019
You are given an unsorted array A[] consisting of N elements and you need to remove all the duplicate elements from the array. All the elements in the resultant array must be unique.
You are given a sorted and infinite array A and an element K. You need to search for the element K in the array. If found, return the index of the element, else return -1.
You are given an array A[] with n elements. You need to find the maximum sum of a subarray among all subarrays of that array. A subarray of array A[] of length n is a contiguous segment from A[i] through A[j] where 0<= i <= j <= n.
Given an array A[] of n elements and a positive integer K, find the Kth smallest element in the array. It is given that all array elements are distinct.
Given two strings S1 and S2 of size m and n respectively, you need to check whether the two strings are an anagram of each other or not. S1 is an anagram of S2 if the characters of S1 can be rearranged to form S2.
Given an array A[] of size n, you need to find the maximum and minimum element present in the array.Your algorithm should make minimum number of comparisons.
Given an unsorted array A[] consisting of n integers, you need to find the length of the longest consecutive sequence of integers in the array.
Asynchronous coding paradigm enables us to write non-blocking code. This makes the single threaded Javascript run with efficiency. A single thread is like an execution that can do only one thing at a time.