641. Design Circular Deque
Design your implementation of the circular double-ended queue (deque). Implement the MyCircularDeque class: MyCircularDeque(int k) Initializes the deque with a maximum size of k. […]
Design your implementation of the circular double-ended queue (deque). Implement the MyCircularDeque class: MyCircularDeque(int k) Initializes the deque with a maximum size of k. […]
There is an array arr of heights of stone and Geek is standing at the first stone and can jump to one
You are implementing a program to use as your calendar. We can add a new event if adding the event
Given an array arr[] and an integer k. Find the maximum for each and every contiguous subarray of size k. Examples: Input: k = 3,
You are implementing a program to use as your calendar. We can add a new event if adding the event
You are given an array words of size n consisting of non-empty strings. We define the score of a string word as the number of strings words[i] such that word is a prefix of words[i]. For example, if words =
Given a singly linked list of integers. The task is to check if the given linked list is palindrome or
You are given two arrays with positive integers arr1 and arr2. A prefix of a positive integer is an integer formed by one or more of its
Given two strings s and p. Find the smallest window in the string s consisting of all the characters(including duplicates) of the string p. Return “-1”
You are given a 0-indexed string s and a dictionary of words dictionary. You have to break s into one or more non-overlapping substrings such that each substring is
Given an unsorted array arr of of positive integers. One number ‘A‘ from set {1, 2,….,n} is missing and one number ‘B‘